Changeset View
Changeset View
Standalone View
Standalone View
krusader/Konfigurator/kgpanel.cpp
Show First 20 Lines • Show All 87 Lines • ▼ Show 20 Line(s) | 87 | // --------------------------------------------------------------------------------------- | |||
---|---|---|---|---|---|
88 | QGroupBox *groupBox = createFrame(i18n("Navigator bar"), tab); | 88 | QGroupBox *groupBox = createFrame(i18n("Navigator bar"), tab); | ||
89 | QGridLayout *gridLayout = createGridLayout(groupBox); | 89 | QGridLayout *gridLayout = createGridLayout(groupBox); | ||
90 | 90 | | |||
91 | KONFIGURATOR_CHECKBOX_PARAM navigatorbar_settings[] = { | 91 | KONFIGURATOR_CHECKBOX_PARAM navigatorbar_settings[] = { | ||
92 | // cfg_class, cfg_name, default, text, restart, tooltip | 92 | // cfg_class, cfg_name, default, text, restart, tooltip | ||
93 | {"Look&Feel", "Navigator Edit Mode", false, i18n("Edit Mode by default"), true, i18n("Show editable path in Navigator bar by default") }, | 93 | {"Look&Feel", "Navigator Edit Mode", false, i18n("Edit Mode by default"), true, i18n("Show editable path in Navigator bar by default") }, | ||
94 | {"Look&Feel", "Navigator Full Path", false, i18n("Show full path by default"), true, i18n("Always show full path in Navigator bar by default.") }, | 94 | {"Look&Feel", "Navigator Full Path", false, i18n("Show full path by default"), true, i18n("Always show full path in Navigator bar by default.") }, | ||
95 | }; | 95 | }; | ||
96 | cbs = createCheckBoxGroup(2, 0, navigatorbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | 96 | KonfiguratorCheckBoxGroup* cbs = createCheckBoxGroup(2, 0, navigatorbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | ||
97 | gridLayout->addWidget(cbs, 0, 0); | 97 | gridLayout->addWidget(cbs, 0, 0); | ||
98 | 98 | | |||
99 | layout->addWidget(groupBox); | 99 | layout->addWidget(groupBox); | ||
100 | 100 | | |||
101 | // --------------------------------------------------------------------------------------- | 101 | // --------------------------------------------------------------------------------------- | ||
102 | // ------------------------------- Operation --------------------------------------------- | 102 | // ------------------------------- Operation --------------------------------------------- | ||
103 | // --------------------------------------------------------------------------------------- | 103 | // --------------------------------------------------------------------------------------- | ||
104 | groupBox = createFrame(i18n("Operation"), tab); | 104 | groupBox = createFrame(i18n("Operation"), tab); | ||
Show All 15 Lines | |||||
120 | // --------------------------------------------------------------------------------------- | 120 | // --------------------------------------------------------------------------------------- | ||
121 | groupBox = createFrame(i18n("Tabs"), tab); | 121 | groupBox = createFrame(i18n("Tabs"), tab); | ||
122 | gridLayout = createGridLayout(groupBox); | 122 | gridLayout = createGridLayout(groupBox); | ||
123 | 123 | | |||
124 | KONFIGURATOR_CHECKBOX_PARAM tabbar_settings[] = { // cfg_class cfg_name default text restart tooltip | 124 | KONFIGURATOR_CHECKBOX_PARAM tabbar_settings[] = { // cfg_class cfg_name default text restart tooltip | ||
125 | {"Look&Feel", "Fullpath Tab Names", _FullPathTabNames, i18n("Use full path tab names"), true , i18n("Display the full path in the folder tabs. By default only the last part of the path is displayed.") }, | 125 | {"Look&Feel", "Fullpath Tab Names", _FullPathTabNames, i18n("Use full path tab names"), true , i18n("Display the full path in the folder tabs. By default only the last part of the path is displayed.") }, | ||
126 | {"Look&Feel", "Show Tab Buttons", true, i18n("Show new/close tab buttons"), true , i18n("Show the new/close tab buttons.") }, | 126 | {"Look&Feel", "Show Tab Buttons", true, i18n("Show new/close tab buttons"), true , i18n("Show the new/close tab buttons.") }, | ||
127 | }; | 127 | }; | ||
128 | KonfiguratorCheckBoxGroup *cbs = createCheckBoxGroup(2, 0, tabbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | 128 | cbs = createCheckBoxGroup(2, 0, tabbar_settings, 2 /*count*/, groupBox, PAGE_GENERAL); | ||
129 | gridLayout->addWidget(cbs, 0, 0, 1, 2); | 129 | gridLayout->addWidget(cbs, 0, 0, 1, 2); | ||
130 | 130 | | |||
131 | // ----------------- Tab Bar position ---------------------------------- | 131 | // ----------------- Tab Bar position ---------------------------------- | ||
132 | QHBoxLayout *hbox = new QHBoxLayout(); | 132 | QHBoxLayout *hbox = new QHBoxLayout(); | ||
133 | 133 | | |||
134 | hbox->addWidget(new QLabel(i18n("Tab Bar position:"), groupBox)); | 134 | hbox->addWidget(new QLabel(i18n("Tab Bar position:"), groupBox)); | ||
135 | 135 | | |||
136 | KONFIGURATOR_NAME_VALUE_PAIR positions[] = { | 136 | KONFIGURATOR_NAME_VALUE_PAIR positions[] = { | ||
Show All 23 Lines | 157 | // --------------------------------------------------------------------------------------- | |||
160 | 160 | | |||
161 | KONFIGURATOR_CHECKBOX_PARAM quicksearch[] = { // cfg_class cfg_name default text restart tooltip | 161 | KONFIGURATOR_CHECKBOX_PARAM quicksearch[] = { // cfg_class cfg_name default text restart tooltip | ||
162 | {"Look&Feel", "New Style Quicksearch", _NewStyleQuicksearch, i18n("Start by typing"), false, i18n("Open search bar and start searching by typing in panel.") }, | 162 | {"Look&Feel", "New Style Quicksearch", _NewStyleQuicksearch, i18n("Start by typing"), false, i18n("Open search bar and start searching by typing in panel.") }, | ||
163 | {"Look&Feel", "Case Sensitive Quicksearch", _CaseSensitiveQuicksearch, i18n("Case sensitive"), false, i18n("Search must match case.") }, | 163 | {"Look&Feel", "Case Sensitive Quicksearch", _CaseSensitiveQuicksearch, i18n("Case sensitive"), false, i18n("Search must match case.") }, | ||
164 | {"Look&Feel", "Up/Down Cancels Quicksearch", false, i18n("Up/Down cancels search"), false, i18n("Pressing the Up/Down buttons closes the search bar (only in search mode).") }, | 164 | {"Look&Feel", "Up/Down Cancels Quicksearch", false, i18n("Up/Down cancels search"), false, i18n("Pressing the Up/Down buttons closes the search bar (only in search mode).") }, | ||
165 | {"Look&Feel", "Navigation with Right Arrow Quicksearch", _NavigationWithRightArrowQuicksearch, i18n("Directory navigation with Right Arrow"), false, i18n("Pressing the Right button enters directory if no search text editing intention is captured.") }, | 165 | {"Look&Feel", "Navigation with Right Arrow Quicksearch", _NavigationWithRightArrowQuicksearch, i18n("Directory navigation with Right Arrow"), false, i18n("Pressing the Right button enters directory if no search text editing intention is captured.") }, | ||
166 | }; | 166 | }; | ||
167 | 167 | | |||
168 | quicksearchCheckboxes = createCheckBoxGroup(2, 0, quicksearch, 4 /*count*/, groupBox, PAGE_GENERAL); | 168 | cbs = createCheckBoxGroup(2, 0, quicksearch, 4 /*count*/, groupBox, PAGE_GENERAL); | ||
169 | gridLayout->addWidget(quicksearchCheckboxes, 0, 0, 1, -1); | 169 | gridLayout->addWidget(cbs, 0, 0, 1, -1); | ||
170 | connect(quicksearchCheckboxes->find("New Style Quicksearch"), SIGNAL(stateChanged(int)), this, SLOT(slotDisable())); | | |||
171 | slotDisable(); | | |||
172 | 170 | | |||
173 | // -------------- Search bar position ----------------------- | 171 | // -------------- Search bar position ----------------------- | ||
174 | 172 | | |||
175 | hbox = new QHBoxLayout(); | 173 | hbox = new QHBoxLayout(); | ||
176 | hbox->addWidget(new QLabel(i18n("Position:"), groupBox)); | 174 | hbox->addWidget(new QLabel(i18n("Position:"), groupBox)); | ||
177 | cmb = createComboBox("Look&Feel", "Quicksearch Position", | 175 | cmb = createComboBox("Look&Feel", "Quicksearch Position", | ||
178 | "bottom", positions, 2, groupBox, true, false, PAGE_GENERAL); | 176 | "bottom", positions, 2, groupBox, true, false, PAGE_GENERAL); | ||
179 | hbox->addWidget(cmb); | 177 | hbox->addWidget(cmb); | ||
180 | hbox->addWidget(createSpacer(groupBox)); | 178 | hbox->addWidget(createSpacer(groupBox)); | ||
181 | gridLayout->addLayout(hbox, 1, 0); | 179 | gridLayout->addLayout(hbox, 1, 0); | ||
182 | layout->addWidget(groupBox); | | |||
183 | 180 | | |||
184 | // -------------- Default search mode ----------------------- | 181 | // -------------- Default search mode ----------------------- | ||
185 | 182 | | |||
186 | hbox = new QHBoxLayout(); | 183 | hbox = new QHBoxLayout(); | ||
187 | hbox->addWidget(new QLabel(i18n("Default mode:"), groupBox)); | 184 | hbox->addWidget(new QLabel(i18n("Default mode:"), groupBox)); | ||
188 | KONFIGURATOR_NAME_VALUE_PAIR modes[] = { | 185 | KONFIGURATOR_NAME_VALUE_PAIR modes[] = { | ||
189 | { i18n("Search"), QString::number(KrSearchBar::MODE_SEARCH) }, | 186 | {i18n("Search"), QString::number(KrSearchBar::MODE_SEARCH)}, | ||
190 | { i18n("Select"), QString::number(KrSearchBar::MODE_SELECT) }, | 187 | {i18n("Select"), QString::number(KrSearchBar::MODE_SELECT)}, | ||
191 | { i18n("Filter"), QString::number(KrSearchBar::MODE_FILTER) } | 188 | {i18n("Filter"), QString::number(KrSearchBar::MODE_FILTER)}}; | ||
192 | }; | | |||
193 | cmb = createComboBox("Look&Feel", "Default Search Mode", | 189 | cmb = createComboBox("Look&Feel", "Default Search Mode", | ||
194 | QString::number(KrSearchBar::MODE_SEARCH), modes, 3, groupBox, true, false, PAGE_GENERAL); | 190 | QString::number(KrSearchBar::MODE_SEARCH), modes, 3, groupBox, true, false, | ||
191 | PAGE_GENERAL); | ||||
195 | cmb->setToolTip(i18n("Set the default mode on first usage")); | 192 | cmb->setToolTip(i18n("Set the default mode on first usage")); | ||
196 | hbox->addWidget(cmb); | 193 | hbox->addWidget(cmb); | ||
197 | hbox->addWidget(createSpacer(groupBox)); | 194 | hbox->addWidget(createSpacer(groupBox)); | ||
198 | gridLayout->addLayout(hbox, 1, 1); | 195 | gridLayout->addLayout(hbox, 1, 1); | ||
196 | | ||||
199 | layout->addWidget(groupBox); | 197 | layout->addWidget(groupBox); | ||
200 | 198 | | |||
201 | // -------------------------------------------------------------------------------------------- | 199 | // -------------------------------------------------------------------------------------------- | ||
202 | // ------------------------------- Bookmark search settings ---------------------------------- | 200 | // ------------------------------- Bookmark search settings ---------------------------------- | ||
203 | // -------------------------------------------------------------------------------------------- | 201 | // -------------------------------------------------------------------------------------------- | ||
204 | groupBox = createFrame(i18n("Bookmark Search"), tab); | 202 | groupBox = createFrame(i18n("Bookmark Search"), tab); | ||
205 | gridLayout = createGridLayout(groupBox); | 203 | gridLayout = createGridLayout(groupBox); | ||
206 | 204 | | |||
▲ Show 20 Lines • Show All 494 Lines • ▼ Show 20 Line(s) | 696 | createComboBox("MediaMenu", "ShowSize", | |||
701 | tab, false, false, PAGE_MEDIA_MENU); | 699 | tab, false, false, PAGE_MEDIA_MENU); | ||
702 | showSizeHBox->addWidget(showSizeCmb); | 700 | showSizeHBox->addWidget(showSizeCmb); | ||
703 | showSizeHBox->addStretch(); | 701 | showSizeHBox->addStretch(); | ||
704 | tabLayout->addLayout(showSizeHBox); | 702 | tabLayout->addLayout(showSizeHBox); | ||
705 | 703 | | |||
706 | tabLayout->addStretch(); | 704 | tabLayout->addStretch(); | ||
707 | } | 705 | } | ||
708 | 706 | | |||
709 | void KgPanel::slotDisable() | | |||
710 | { | | |||
711 | bool isNewStyleQuickSearch = quicksearchCheckboxes->find("New Style Quicksearch")->isChecked(); | | |||
712 | quicksearchCheckboxes->find("Case Sensitive Quicksearch")->setEnabled(isNewStyleQuickSearch); | | |||
713 | } | | |||
714 | | ||||
715 | void KgPanel::slotEnablePanelToolbar() | 707 | void KgPanel::slotEnablePanelToolbar() | ||
716 | { | 708 | { | ||
717 | bool enableTB = buttonsCheckboxes->find("Panel Toolbar visible")->isChecked(); | 709 | bool enableTB = buttonsCheckboxes->find("Panel Toolbar visible")->isChecked(); | ||
718 | panelToolbarButtonsCheckboxes->find("Root Button Visible")->setEnabled(enableTB); | 710 | panelToolbarButtonsCheckboxes->find("Root Button Visible")->setEnabled(enableTB); | ||
719 | panelToolbarButtonsCheckboxes->find("Home Button Visible")->setEnabled(enableTB); | 711 | panelToolbarButtonsCheckboxes->find("Home Button Visible")->setEnabled(enableTB); | ||
720 | panelToolbarButtonsCheckboxes->find("Up Button Visible")->setEnabled(enableTB); | 712 | panelToolbarButtonsCheckboxes->find("Up Button Visible")->setEnabled(enableTB); | ||
721 | panelToolbarButtonsCheckboxes->find("Equal Button Visible")->setEnabled(enableTB); | 713 | panelToolbarButtonsCheckboxes->find("Equal Button Visible")->setEnabled(enableTB); | ||
722 | panelToolbarButtonsCheckboxes->find("SyncBrowse Button Visible")->setEnabled(enableTB); | 714 | panelToolbarButtonsCheckboxes->find("SyncBrowse Button Visible")->setEnabled(enableTB); | ||
Show All 31 Lines |