Summary: | opening and closing right pane with tag filter also changes width of left pane and vv | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | Wilbert Berendsen <wbsoft> |
Component: | Usability-Ergonomy | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | caulier.gilles |
Priority: | NOR | ||
Version: | 0.8.0 | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 0.9.0 | |
Sentry Crash Report: |
Description
Wilbert Berendsen
2005-11-01 09:30:33 UTC
s/shrinked/shrunk/ :-) SVN commit 524901 by cgilles: digikam from trunk : Bug fix : set properlly main widget size before to apply sidebar size using QSizePolicy. Thi scommit fix all windows (editor, image plugins, showfoto, etc.) exepted main interface (still todo). CCMAIL: digikam-devel@kde.org CCBUGS: 115460 M +4 -1 libs/dialogs/imagedlgbase.cpp M +6 -5 libs/dialogs/imageguidedlg.cpp M +4 -3 libs/widgets/imageplugins/imagepannelwidget.cpp M +9 -1 showfoto/showfoto.cpp M +1 -1 utilities/cameragui/cameraiconview.cpp M +7 -3 utilities/cameragui/cameraui.cpp M +7 -4 utilities/imageeditor/editor/imagewindow.cpp --- trunk/extragear/graphics/digikam/libs/dialogs/imagedlgbase.cpp #524900:524901 @@ -131,8 +131,11 @@ d->hbox = new QHBox(plainPage()); d->splitter = new QSplitter(d->hbox); + d->splitter->setFrameStyle( QFrame::NoFrame ); + d->splitter->setFrameShadow( QFrame::Plain ); + d->splitter->setFrameShape( QFrame::NoFrame ); + d->splitter->setOpaqueResize(false); - d->splitter->setOpaqueResize(false); d->mainLayout->addMultiCellWidget(d->hbox, 1, 2, 0, 1); d->mainLayout->setColStretch(0, 10); d->mainLayout->setRowStretch(2, 10); --- trunk/extragear/graphics/digikam/libs/dialogs/imageguidedlg.cpp #524900:524901 @@ -175,13 +175,14 @@ d->hbox = new QHBox(plainPage()); d->splitter = new QSplitter(d->hbox); - m_imagePreviewWidget = new ImageWidget(d->splitter, desc, prevModeOptions, - guideMode, guideVisible); + m_imagePreviewWidget = new ImageWidget(d->splitter, desc, prevModeOptions, guideMode, guideVisible); + d->splitter->setFrameStyle( QFrame::NoFrame ); + d->splitter->setFrameShadow( QFrame::Plain ); + d->splitter->setFrameShape( QFrame::NoFrame ); d->splitter->setOpaqueResize(false); - QSizePolicy rightSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 2, 1); + + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); m_imagePreviewWidget->setSizePolicy(rightSzPolicy); QString sbName(d->name + QString(" Image Plugin Sidebar")); --- trunk/extragear/graphics/digikam/libs/widgets/imageplugins/imagepannelwidget.cpp #524900:524901 @@ -116,6 +116,9 @@ d->previewWidget = new QWidget(d->splitter); d->mainLayout = new QGridLayout( d->previewWidget, 2, 2, 0, KDialog::spacingHint()); + d->splitter->setFrameStyle( QFrame::NoFrame ); + d->splitter->setFrameShadow( QFrame::Plain ); + d->splitter->setFrameShape( QFrame::NoFrame ); d->splitter->setOpaqueResize(false); // ------------------------------------------------------------- @@ -131,9 +134,7 @@ "image to change the clip focus.")); l1->addWidget(d->imageRegionWidget, 0); - QSizePolicy rightSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 2, 1); + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); d->previewWidget->setSizePolicy(rightSzPolicy); // ------------------------------------------------------------- --- trunk/extragear/graphics/digikam/showfoto/showfoto.cpp #524900:524901 @@ -247,12 +247,15 @@ config->setGroup("ImageViewer Settings"); QWidget* widget = new QWidget(this); - + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); + if(!config->readBoolEntry("HorizontalThumbbar", false)) // Vertical thumbbar layout { QHBoxLayout *hlay = new QHBoxLayout(widget); m_splitter = new QSplitter(widget); m_canvas = new Digikam::Canvas(m_splitter); + m_canvas->setSizePolicy(rightSzPolicy); + m_rightSidebar = new Digikam::ImagePropertiesSideBar(widget, "ShowFoto Sidebar Right", m_splitter, Digikam::Sidebar::Right); m_bar = new Digikam::ThumbBarView(widget, Digikam::ThumbBarView::Vertical); @@ -267,6 +270,8 @@ QWidget* widget2 = new QWidget(m_splitter); QVBoxLayout *vlay = new QVBoxLayout(widget2); m_canvas = new Digikam::Canvas(widget2); + m_canvas->setSizePolicy(rightSzPolicy); + m_bar = new Digikam::ThumbBarView(widget2, Digikam::ThumbBarView::Horizontal); vlay->addWidget(m_canvas); @@ -280,6 +285,9 @@ hlay->addWidget(m_rightSidebar); } + m_splitter->setFrameStyle( QFrame::NoFrame ); + m_splitter->setFrameShadow( QFrame::Plain ); + m_splitter->setFrameShape( QFrame::NoFrame ); m_splitter->setOpaqueResize(false); setCentralWidget(widget); m_rightSidebar->loadViewState(); --- trunk/extragear/graphics/digikam/utilities/cameragui/cameraiconview.cpp #524900:524901 @@ -55,7 +55,7 @@ m_groupItem(new IconGroupItem(this)) { setHScrollBarMode(QScrollView::AlwaysOff); - setMinimumSize(300, 300); + setMinimumSize(450, 400); CameraIconViewItem::m_newEmblem = new QPixmap(CameraIconViewItem::new_xpm); --- trunk/extragear/graphics/digikam/utilities/cameragui/cameraui.cpp #524900:524901 @@ -160,8 +160,15 @@ QHBox* widget = new QHBox(plainPage()); d->splitter = new QSplitter(widget); d->view = new CameraIconView(this, d->splitter); + + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); + d->view->setSizePolicy(rightSzPolicy); + d->rightSidebar = new ImagePropertiesSideBarCamGui(widget, "CameraGui Sidebar Right", d->splitter, Digikam::Sidebar::Right, true); + d->splitter->setFrameStyle( QFrame::NoFrame ); + d->splitter->setFrameShadow( QFrame::Plain ); + d->splitter->setFrameShape( QFrame::NoFrame ); d->splitter->setOpaqueResize(false); // ------------------------------------------------------------------------- @@ -354,9 +361,6 @@ config->setGroup("Camera Settings"); d->autoRotateCheck->setChecked(config->readBoolEntry("AutoRotate", true)); d->autoAlbumCheck->setChecked(config->readBoolEntry("AutoAlbum", false)); - - QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); - d->view->setSizePolicy(rightSzPolicy); if(config->hasKey("Splitter Sizes")) d->splitter->setSizes(config->readIntListEntry("Splitter Sizes")); --- trunk/extragear/graphics/digikam/utilities/imageeditor/editor/imagewindow.cpp #524900:524901 @@ -194,15 +194,18 @@ m_splitter = new QSplitter(widget); m_canvas = new Canvas(m_splitter); + + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); + m_canvas->setSizePolicy(rightSzPolicy); + m_rightSidebar = new ImagePropertiesSideBarDB(widget, "ImageEditor Right Sidebar", m_splitter, Sidebar::Right, true, false); + lay->addWidget(m_splitter); + lay->addWidget(m_rightSidebar); + m_splitter->setFrameStyle( QFrame::NoFrame ); m_splitter->setFrameShadow( QFrame::Plain ); m_splitter->setFrameShape( QFrame::NoFrame ); - - lay->addWidget(m_splitter); - lay->addWidget(m_rightSidebar); - m_splitter->setOpaqueResize(false); setCentralWidget(widget); } SVN commit 524908 by cgilles: digikam from trunk : Bug fix : set properlly main widget size from main interface before to apply sidebar size using QSizePolicy. CCMAIL: digikam-devel@kde.org CCBUGS: 115460 M +6 -13 digikamview.cpp --- trunk/extragear/graphics/digikam/digikam/digikamview.cpp #524907:524908 @@ -72,14 +72,17 @@ { mParent = static_cast<DigikamApp *>(parent); mAlbumMan = AlbumManager::instance(); - mMainSidebar = new Digikam::Sidebar(this, "Digikam Left Sidebar", Digikam::Sidebar::Left); + mMainSidebar = new Sidebar(this, "Digikam Left Sidebar", Sidebar::Left); mSplitter = new QSplitter(this); mMainSidebar->setSplitter(mSplitter); mIconView = new AlbumIconView(mSplitter); - mRightSidebar = new Digikam::ImagePropertiesSideBarDB(this, "Digikam Right Sidebar", mSplitter, - Digikam::Sidebar::Right, true, true); + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); + mIconView->setSizePolicy(rightSzPolicy); + + mRightSidebar = new ImagePropertiesSideBarDB(this, "Digikam Right Sidebar", mSplitter, + Sidebar::Right, true, true); // To the left. mFolderView = new AlbumFolderView(this); @@ -181,22 +184,12 @@ void DigikamView::loadViewState() { - QSizePolicy leftSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 1, 1); - QSizePolicy rightSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 2, 1); KConfig *config = kapp->config(); config->setGroup("MainWindow"); if(config->hasKey("SplitterSizes")) { mSplitter->setSizes(config->readIntListEntry("SplitterSizes")); } - else - { - mIconView->setSizePolicy(rightSzPolicy); - } mInitialAlbumID = config->readNumEntry("InitialAlbumID", 0); } Fixed. I close this file. Gilles Caulier SVN commit 525080 by cgilles: digikam from stable : fix sidebar sizes and splitter border attributes from main interface. CCBUGS: 115460 M +20 -26 digikamview.cpp --- branches/stable/extragear/graphics/digikam/digikam/digikamview.cpp #525079:525080 @@ -68,26 +68,30 @@ DigikamView::DigikamView(QWidget *parent) : QHBox(parent) { - mParent = static_cast<DigikamApp *>(parent); + mParent = static_cast<DigikamApp *>(parent); + mAlbumMan = AlbumManager::instance(); + mMainSidebar = new Digikam::Sidebar(this, Digikam::Sidebar::Left); - mAlbumMan = AlbumManager::instance(); + mSplitter = new QSplitter(this); + msplitter->setFrameStyle( QFrame::NoFrame ); + msplitter->setFrameShadow( QFrame::Plain ); + msplitter->setFrameShape( QFrame::NoFrame ); + mSplitter->setOpaqueResize(false); - mMainSidebar = new Digikam::Sidebar(this, Digikam::Sidebar::Left); - - mSplitter = new QSplitter(this); - mMainSidebar->setSplitter(mSplitter); mIconView = new AlbumIconView(mSplitter); + QSizePolicy rightSzPolicy(QSizePolicy::Preferred, QSizePolicy::Expanding, 2, 1); + mIconView->setSizePolicy(rightSzPolicy); mRightSidebar = new Digikam::Sidebar(this, Digikam::Sidebar::Right, true); mRightSidebar->setSplitter(mSplitter); - mFolderView = new AlbumFolderView(this); - mDateFolderView = new DateFolderView(this); - mTagFolderView = new TagFolderView(this); + mFolderView = new AlbumFolderView(this); + mDateFolderView = new DateFolderView(this); + mTagFolderView = new TagFolderView(this); mSearchFolderView = new SearchFolderView(this); - mTagFilterView = new TagFilterView(this); + mTagFilterView = new TagFilterView(this); mMainSidebar->appendTab(mFolderView, SmallIcon("folder"), i18n("Albums")); mMainSidebar->appendTab(mDateFolderView, SmallIcon("date"), i18n("Dates")); @@ -124,10 +128,13 @@ connect(mAlbumMan, SIGNAL(signalAlbumCurrentChanged(Album*)), this, SLOT(slot_albumSelected(Album*))); + connect(mAlbumMan, SIGNAL(signalAlbumsCleared()), this, SLOT(slot_albumsCleared())); + connect(mAlbumMan, SIGNAL(signalAlbumDeleted(Album*)), this, SLOT(slotAlbumDeleted(Album*))); + connect(mAlbumMan, SIGNAL(signalAllAlbumsLoaded()), this, SLOT(slotAllAlbumsLoaded())); @@ -151,31 +158,18 @@ // -- Sidebar Connections ------------------------------------- connect(mMainSidebar, SIGNAL(signalChangedTab(QWidget*)), - SLOT(slotLeftSidebarChangedTab(QWidget*))); - + this, SLOT(slotLeftSidebarChangedTab(QWidget*))); } void DigikamView::loadViewState() { - QSizePolicy leftSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 1, 1); - QSizePolicy rightSzPolicy(QSizePolicy::Preferred, - QSizePolicy::Expanding, - 2, 1); KConfig *config = kapp->config(); config->setGroup("MainWindow"); + if(config->hasKey("SplitterSizes")) - { mSplitter->setSizes(config->readIntListEntry("SplitterSizes")); - } - else - { - mIconView->setSizePolicy(rightSzPolicy); - } - mInitialAlbumID = config->readNumEntry("InitialAlbumID", 0); - + mInitialAlbumID = config->readNumEntry("InitialAlbumID", 0); } void DigikamView::saveViewState() |