Patch from issue 975 on behalf of Phil: "Proposition of a patch right Pannel (new visual rendering <-> icons instead of text)"
It moreover better handle workflow changes: no need to restart RT for some options.
This commit is contained in:
BIN
rtdata/images/colour-24.png
Normal file
BIN
rtdata/images/colour-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.2 KiB |
BIN
rtdata/images/detail-24.png
Normal file
BIN
rtdata/images/detail-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.7 KiB |
BIN
rtdata/images/exif-24.png
Normal file
BIN
rtdata/images/exif-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 912 B |
BIN
rtdata/images/exposure-24.png
Normal file
BIN
rtdata/images/exposure-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 702 B |
BIN
rtdata/images/raw-24.png
Normal file
BIN
rtdata/images/raw-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 338 B |
BIN
rtdata/images/transform-24.png
Normal file
BIN
rtdata/images/transform-24.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
@@ -681,7 +681,9 @@ PREFERENCES_TAB_IMPROC;Traitement de l'image
|
||||
PREFERENCES_TAB_OUTPUT;Options de sortie
|
||||
PREFERENCES_TAB_SOUND;Sons
|
||||
PREFERENCES_THUMBSIZE;Tailles des vignettes
|
||||
PREFERENCES_TP_VSCROLLBAR;Cacher la barre de défilement verticale du panneau des outils
|
||||
PREFERENCES_TP_LABEL;Panneau des outils:
|
||||
PREFERENCES_TP_USEICONORTEXT;Utiliser des icônes au lieu de textes
|
||||
PREFERENCES_TP_VSCROLLBAR;Cacher la barre de défilement verticale
|
||||
PREFERENCES_TUNNELMETADATA;Copier les données IPTC/XMP sans les\nchanger dans fichier de sortie
|
||||
PREFERENCES_USESYSTEMTHEME;Utiliser le thème système
|
||||
PREFERENCES_WORKFLOW;Habitudes de travail
|
||||
|
@@ -676,7 +676,9 @@ PREFERENCES_TAB_IMPROC;Image Processing
|
||||
PREFERENCES_TAB_OUTPUT;Output Options
|
||||
PREFERENCES_TAB_SOUND;Sounds
|
||||
PREFERENCES_THUMBSIZE;Thumbnail Size
|
||||
PREFERENCES_TP_VSCROLLBAR;Hide tool panel's vertical scrollbar
|
||||
PREFERENCES_TP_LABEL;Tool panel:
|
||||
PREFERENCES_TP_USEICONORTEXT;Use tab icons instead of text
|
||||
PREFERENCES_TP_VSCROLLBAR;Hide vertical scrollbar
|
||||
PREFERENCES_TUNNELMETADATA;Copy IPTC/XMP unchanged to output file (when tagging with other program)
|
||||
PREFERENCES_USESYSTEMTHEME; Use System Theme
|
||||
PREFERENCES_WORKFLOW;Layout
|
||||
|
@@ -35,6 +35,8 @@ BatchToolPanelCoordinator::BatchToolPanelCoordinator (FilePanel* parent) : ToolP
|
||||
if (ipi!=toolPanels.end())
|
||||
toolPanels.erase (ipi);
|
||||
toolPanelNotebook->remove_page (*metadataPanel);
|
||||
metadataPanel = 0;
|
||||
toiM = 0;
|
||||
|
||||
for (int i=0; i<toolPanels.size(); i++)
|
||||
toolPanels[i]->setBatchMode (true);
|
||||
|
@@ -50,13 +50,10 @@ EditorPanel::EditorPanel (FilePanel* filePanel)
|
||||
leftbox->set_border_width (2);
|
||||
leftbox->set_size_request(100,250);
|
||||
|
||||
if (options.histogramPosition>0) {
|
||||
histogramPanel = Gtk::manage (new HistogramPanel ());
|
||||
if (options.histogramPosition==1) leftbox->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 4);
|
||||
} else histogramPanel = NULL;
|
||||
histogramPanel = NULL;
|
||||
|
||||
profilep = Gtk::manage (new ProfilePanel ());
|
||||
Gtk::Frame* ppframe = Gtk::manage (new Gtk::Frame ());
|
||||
ppframe = new Gtk::Frame ();
|
||||
ppframe->add (*profilep);
|
||||
ppframe->set_label (M("PROFILEPANEL_LABEL"));
|
||||
//leftbox->pack_start (*ppframe, Gtk::PACK_SHRINK, 4);
|
||||
@@ -160,7 +157,6 @@ EditorPanel::EditorPanel (FilePanel* filePanel)
|
||||
|
||||
vboxright->set_border_width (2);
|
||||
|
||||
if (options.histogramPosition==2) vboxright->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 2);
|
||||
if (options.showProfileSelector) vboxright->pack_start (*ppframe, Gtk::PACK_SHRINK, 2);
|
||||
// main notebook
|
||||
vboxright->pack_start (*tpc->toolPanelNotebook);
|
||||
@@ -251,6 +247,9 @@ EditorPanel::EditorPanel (FilePanel* filePanel)
|
||||
hpanedr->signal_button_release_event().connect_notify( sigc::mem_fun(*this, &EditorPanel::rightPaneButtonReleased) );
|
||||
|
||||
pack_start (*hpanedr);
|
||||
|
||||
updateHistogramPosition (0, options.histogramPosition);
|
||||
|
||||
show_all ();
|
||||
|
||||
// save as dialog
|
||||
@@ -270,7 +269,6 @@ EditorPanel::EditorPanel (FilePanel* filePanel)
|
||||
tpc->addPParamsChangeListener (this);
|
||||
iarea->imageArea->setCropGUIListener (tpc->getCropGUIListener());
|
||||
iarea->imageArea->setPointerMotionListener (navigator);
|
||||
iarea->imageArea->setPointerMotionHListener (histogramPanel);
|
||||
iarea->imageArea->setImageAreaToolListener (tpc);
|
||||
|
||||
// initialize components
|
||||
@@ -321,6 +319,7 @@ EditorPanel::~EditorPanel () {
|
||||
|
||||
delete tpc;
|
||||
|
||||
delete ppframe;
|
||||
delete leftbox;
|
||||
delete vboxright;
|
||||
delete saveAsDialog;
|
||||
@@ -1325,3 +1324,76 @@ void EditorPanel::tbShowHideSidePanels_managestate(){
|
||||
void EditorPanel::updateTPVScrollbar (bool hide) {
|
||||
tpc->updateTPVScrollbar (hide);
|
||||
}
|
||||
|
||||
void EditorPanel::updateTabsUsesIcons (bool useIcons) {
|
||||
tpc->updateTabsUsesIcons (useIcons);
|
||||
}
|
||||
|
||||
void EditorPanel::updateProfileSelector (bool showMe) {
|
||||
if (showMe) {
|
||||
// add the profile panel
|
||||
vboxright->pack_start (*ppframe, Gtk::PACK_SHRINK, 2);
|
||||
vboxright->reorder_child(*ppframe, 0 + (options.histogramPosition==2?1:0));
|
||||
ppframe->show_all();
|
||||
}
|
||||
else {
|
||||
// remove (but don't delete) the profile panel
|
||||
removeIfThere(vboxright, ppframe, false);
|
||||
}
|
||||
}
|
||||
|
||||
void EditorPanel::updateHistogramPosition (int oldPosition, int newPosition) {
|
||||
|
||||
switch (newPosition) {
|
||||
case 0:
|
||||
// No histogram
|
||||
if (!oldPosition) {
|
||||
// An histogram actually exist, we delete it
|
||||
if (oldPosition == 1)
|
||||
removeIfThere(leftbox, histogramPanel, false);
|
||||
else if (oldPosition == 2)
|
||||
removeIfThere(vboxright, histogramPanel, false);
|
||||
delete histogramPanel;
|
||||
histogramPanel = NULL;
|
||||
}
|
||||
// else no need to create it
|
||||
break;
|
||||
case 1:
|
||||
// Histogram on the left pane
|
||||
if (oldPosition == 0) {
|
||||
// There was no Histogram before, so we create it
|
||||
histogramPanel = Gtk::manage (new HistogramPanel ());
|
||||
leftbox->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 2);
|
||||
}
|
||||
else if (oldPosition == 2) {
|
||||
// The histogram was on the right side, so we move it to the left
|
||||
histogramPanel->reference();
|
||||
removeIfThere(vboxright, histogramPanel, false);
|
||||
leftbox->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 2);
|
||||
histogramPanel->unreference();
|
||||
}
|
||||
histogramPanel->reorder(Gtk::ALIGN_LEFT);
|
||||
leftbox->reorder_child(*histogramPanel, 0);
|
||||
break;
|
||||
case 2:
|
||||
default:
|
||||
// Histogram on the right pane
|
||||
if (oldPosition == 0) {
|
||||
// There was no Histogram before, so we create it
|
||||
histogramPanel = Gtk::manage (new HistogramPanel ());
|
||||
vboxright->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 2);
|
||||
}
|
||||
else if (oldPosition == 1) {
|
||||
// The histogram was on the left side, so we move it to the right
|
||||
histogramPanel->reference();
|
||||
removeIfThere(leftbox, histogramPanel, false);
|
||||
vboxright->pack_start (*histogramPanel, Gtk::PACK_SHRINK, 2);
|
||||
histogramPanel->unreference();
|
||||
}
|
||||
histogramPanel->reorder(Gtk::ALIGN_RIGHT);
|
||||
vboxright->reorder_child(*histogramPanel, 0);
|
||||
break;
|
||||
}
|
||||
|
||||
iarea->imageArea->setPointerMotionHListener (histogramPanel);
|
||||
}
|
||||
|
@@ -68,7 +68,8 @@ class EditorPanel : public Gtk::VBox,
|
||||
Gtk::Image *iTopPanel_1_Show, *iTopPanel_1_Hide;
|
||||
Gtk::Image *iRightPanel_1_Show, *iRightPanel_1_Hide;
|
||||
Gtk::Image *iShowHideSidePanels;
|
||||
Gtk::VBox* leftbox, *vboxright;
|
||||
Gtk::VBox *leftbox;
|
||||
Gtk::VBox *vboxright;
|
||||
|
||||
Gtk::Button* queueimg;
|
||||
Gtk::Button* saveimgas;
|
||||
@@ -85,6 +86,7 @@ class EditorPanel : public Gtk::VBox,
|
||||
Gtk::Label* afterLabel;
|
||||
Gtk::HBox* beforeAfterBox;
|
||||
|
||||
Gtk::Frame* ppframe;
|
||||
ProfilePanel* profilep;
|
||||
History* history;
|
||||
HistogramPanel* histogramPanel;
|
||||
@@ -177,7 +179,10 @@ class EditorPanel : public Gtk::VBox,
|
||||
bool handleShortcutKey (GdkEventKey* event);
|
||||
|
||||
bool getIsProcessing() const { return isProcessing; }
|
||||
void updateProfileSelector(bool showMe);
|
||||
void updateTPVScrollbar (bool hide);
|
||||
void updateTabsUsesIcons (bool useIcons);
|
||||
void updateHistogramPosition (int oldPosition, int newPosition);
|
||||
|
||||
Gtk::Paned *catalogPane;
|
||||
};
|
||||
|
@@ -1443,6 +1443,24 @@ void FileCatalog::executeQuery(){
|
||||
FileCatalog::filterChanged ();
|
||||
}
|
||||
|
||||
void FileCatalog::updateFBQueryTB (bool singleRow) {
|
||||
hbToolBar1->reference();
|
||||
if (singleRow) {
|
||||
bool removed = removeIfThere(this, hbToolBar1, false);
|
||||
if (removed) {
|
||||
buttonBar->pack_start(*hbToolBar1, Gtk::PACK_EXPAND_WIDGET, 0);
|
||||
}
|
||||
}
|
||||
else {
|
||||
bool removed = removeIfThere(buttonBar, hbToolBar1, false);
|
||||
if (removed) {
|
||||
pack_start(*hbToolBar1, Gtk::PACK_SHRINK, 0);
|
||||
reorder_child(*hbToolBar1, 0);
|
||||
}
|
||||
}
|
||||
hbToolBar1->unreference();
|
||||
}
|
||||
|
||||
void FileCatalog::buttonBrowsePathPressed () {
|
||||
Glib::ustring BrowsePathValue = BrowsePath->get_text();
|
||||
Glib::ustring DecodedPathPrefix="";
|
||||
|
@@ -218,6 +218,7 @@ class FileCatalog : public Gtk::VBox,
|
||||
void buttonBrowsePathPressed ();
|
||||
void buttonQueryClearPressed ();
|
||||
void executeQuery ();
|
||||
void updateFBQueryTB (bool singleRow);
|
||||
|
||||
void tbLeftPanel_1_toggled ();
|
||||
void tbLeftPanel_1_visible (bool visible);
|
||||
|
@@ -256,3 +256,7 @@ void FilePanel::loadingThumbs(Glib::ustring str, double rate)
|
||||
void FilePanel::updateTPVScrollbar (bool hide) {
|
||||
tpc->updateTPVScrollbar (hide);
|
||||
}
|
||||
|
||||
void FilePanel::updateTabsUsesIcons (bool useIcons) {
|
||||
tpc->updateTabsUsesIcons (useIcons);
|
||||
}
|
||||
|
@@ -83,6 +83,7 @@ class FilePanel : public Gtk::HPaned,
|
||||
|
||||
bool handleShortcutKey (GdkEventKey* event);
|
||||
void updateTPVScrollbar (bool hide);
|
||||
void updateTabsUsesIcons (bool useIcons);
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -351,3 +351,48 @@ bool MyFileChooserButton::on_scroll_event (GdkEventScroll* event) {
|
||||
// ... otherwise the scroll event is sent back to an upper level
|
||||
return false;
|
||||
}
|
||||
|
||||
TextOrIcon::TextOrIcon (Glib::ustring fname, Glib::ustring labelTx, Glib::ustring tooltipTx, TOITypes type) {
|
||||
|
||||
imgIcon = 0;
|
||||
label = 0;
|
||||
filename = fname;
|
||||
labelText = labelTx;
|
||||
tooltipText = tooltipTx;
|
||||
|
||||
switchTo(type);
|
||||
}
|
||||
|
||||
TextOrIcon::~TextOrIcon () {
|
||||
if (imgIcon) delete imgIcon;
|
||||
if (label) delete label;
|
||||
}
|
||||
|
||||
void TextOrIcon::switchTo(TOITypes type) {
|
||||
switch (type) {
|
||||
case (TOI_ICON):
|
||||
if (!imgIcon) {
|
||||
removeIfThere(this, label, false);
|
||||
delete label;
|
||||
label = 0;
|
||||
imgIcon = new Gtk::Image (filename);
|
||||
pack_start(*imgIcon, Gtk::PACK_SHRINK, 0);
|
||||
set_tooltip_markup ("<span font_size=\"large\" font_weight=\"bold\">" + labelText + "</span>\n" + tooltipText);
|
||||
}
|
||||
// do nothing if imgIcon exist, which mean that it is currently being displayed
|
||||
break;
|
||||
case(TOI_TEXT):
|
||||
default:
|
||||
if (!label) {
|
||||
removeIfThere(this, imgIcon, false);
|
||||
delete imgIcon;
|
||||
imgIcon = 0;
|
||||
label = new Gtk::Label (labelText, Gtk::ALIGN_CENTER);
|
||||
pack_start(*label, Gtk::PACK_EXPAND_WIDGET, 0);
|
||||
set_tooltip_markup (tooltipText);
|
||||
}
|
||||
// do nothing if label exist, which mean that it is currently being displayed
|
||||
break;
|
||||
}
|
||||
show_all();
|
||||
}
|
||||
|
@@ -71,6 +71,9 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::ScrolledWindow in order to handle the scrollwheel
|
||||
*/
|
||||
class MyScrolledWindow : public Gtk::ScrolledWindow {
|
||||
|
||||
bool on_scroll_event (GdkEventScroll* event);
|
||||
@@ -79,6 +82,9 @@ public:
|
||||
MyScrolledWindow();
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::ComboBox in order to handle the scrollwheel
|
||||
*/
|
||||
class MyComboBox : public Gtk::ComboBox {
|
||||
|
||||
bool on_scroll_event (GdkEventScroll* event);
|
||||
@@ -87,6 +93,9 @@ public:
|
||||
MyComboBox ();
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::ComboBoxText in order to handle the scrollwheel
|
||||
*/
|
||||
class MyComboBoxText : public Gtk::ComboBoxText {
|
||||
|
||||
bool on_scroll_event (GdkEventScroll* event);
|
||||
@@ -95,6 +104,9 @@ public:
|
||||
MyComboBoxText ();
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::SpinButton in order to handle the scrollwheel
|
||||
*/
|
||||
class MySpinButton : public Gtk::SpinButton {
|
||||
|
||||
bool on_scroll_event (GdkEventScroll* event);
|
||||
@@ -103,11 +115,17 @@ public:
|
||||
MySpinButton ();
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::HScale in order to handle the scrollwheel
|
||||
*/
|
||||
class MyHScale : public Gtk::HScale {
|
||||
|
||||
bool on_scroll_event (GdkEventScroll* event);
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief subclass of Gtk::FileChooserButton in order to handle the scrollwheel
|
||||
*/
|
||||
class MyFileChooserButton : public Gtk::FileChooserButton {
|
||||
|
||||
protected:
|
||||
@@ -117,4 +135,28 @@ public:
|
||||
MyFileChooserButton (const Glib::ustring& title, Gtk::FileChooserAction action=Gtk::FILE_CHOOSER_ACTION_OPEN);
|
||||
};
|
||||
|
||||
enum TOITypes {
|
||||
TOI_TEXT,
|
||||
TOI_ICON
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Handle the switch between text and image to be displayed in the HBox (to be used in a button/toolpanel)
|
||||
*/
|
||||
class TextOrIcon : public Gtk::HBox {
|
||||
|
||||
protected:
|
||||
Gtk::Image* imgIcon;
|
||||
Gtk::Label* label;
|
||||
Glib::ustring filename;
|
||||
Glib::ustring labelText;
|
||||
Glib::ustring tooltipText;
|
||||
|
||||
public:
|
||||
TextOrIcon (Glib::ustring filename, Glib::ustring labelTx, Glib::ustring tooltipTx, TOITypes type);
|
||||
~TextOrIcon ();
|
||||
|
||||
void switchTo(TOITypes type);
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -84,7 +84,7 @@ HistogramPanel::HistogramPanel () {
|
||||
showRAW->set_tooltip_text (M("HISTOGRAM_TOOLTIP_RAW"));
|
||||
showBAR->set_tooltip_text (M("HISTOGRAM_TOOLTIP_BAR"));
|
||||
|
||||
Gtk::VBox* buttonVBox = Gtk::manage (new Gtk::VBox (false, 2));
|
||||
buttonVBox = Gtk::manage (new Gtk::VBox (false, 2));
|
||||
showRed->set_active (true);
|
||||
showGreen->set_active (true);
|
||||
showBlue->set_active (true);
|
||||
@@ -194,6 +194,17 @@ void HistogramPanel::pointerMoved (bool validPos, Glib::ustring profile, int x,
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Move the vertical button bar to the right side
|
||||
* only allowed values for align are Gtk::ALIGN_LEFT and Gtk::ALIGN_RIGHT
|
||||
*/
|
||||
void HistogramPanel::reorder (Gtk::AlignmentEnum align) {
|
||||
if (align == Gtk::ALIGN_LEFT)
|
||||
reorder_child(*buttonVBox, 0);
|
||||
else
|
||||
reorder_child(*buttonVBox, 1);
|
||||
}
|
||||
|
||||
//
|
||||
//
|
||||
//
|
||||
@@ -686,7 +697,6 @@ bool HistogramArea::on_expose_event(GdkEventExpose* event) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
bool HistogramArea::on_button_press_event (GdkEventButton* event) {
|
||||
|
||||
if (event->type==GDK_2BUTTON_PRESS && event->button==1) {
|
||||
|
@@ -148,6 +148,7 @@ class HistogramPanel : public Gtk::HBox, public PointerMotionListener {
|
||||
protected:
|
||||
|
||||
Gtk::VBox* gfxVBox;
|
||||
Gtk::VBox* buttonVBox;
|
||||
HistogramArea* histogramArea;
|
||||
HistogramRGBArea* histogramRGBArea;
|
||||
Gtk::ToggleButton* showRed;
|
||||
@@ -174,6 +175,7 @@ class HistogramPanel : public Gtk::HBox, public PointerMotionListener {
|
||||
// TODO should be protected
|
||||
void setHistRGBInvalid ();
|
||||
|
||||
void reorder (Gtk::AlignmentEnum align);
|
||||
void rgbv_toggled ();
|
||||
void resized (Gtk::Allocation& req);
|
||||
};
|
||||
|
@@ -154,6 +154,7 @@ void Options::setDefaults () {
|
||||
showProfileSelector = true;
|
||||
FileBrowserToolbarSingleRow = true;
|
||||
hideTPVScrollbar = false;
|
||||
UseIconNoText = true;
|
||||
squareDetailWindow = false;
|
||||
menuGroupRank = true;
|
||||
menuGroupLabel = true;
|
||||
@@ -405,6 +406,7 @@ if (keyFile.has_group ("GUI")) {
|
||||
if (keyFile.has_key ("GUI", "SquareDetailWindow")) squareDetailWindow = keyFile.get_boolean ("GUI", "SquareDetailWindow");
|
||||
if (keyFile.has_key ("GUI", "FileBrowserToolbarSingleRow")) FileBrowserToolbarSingleRow = keyFile.get_boolean ("GUI", "FileBrowserToolbarSingleRow");
|
||||
if (keyFile.has_key ("GUI", "HideTPVScrollbar")) hideTPVScrollbar = keyFile.get_boolean ("GUI", "HideTPVScrollbar");
|
||||
if (keyFile.has_key ("GUI", "UseIconNoText")) UseIconNoText = keyFile.get_boolean ("GUI", "UseIconNoText");
|
||||
}
|
||||
|
||||
|
||||
@@ -577,6 +579,7 @@ int Options::saveToFile (Glib::ustring fname) {
|
||||
keyFile.set_boolean ("GUI", "SquareDetailWindow", squareDetailWindow);
|
||||
keyFile.set_boolean ("GUI", "FileBrowserToolbarSingleRow", FileBrowserToolbarSingleRow);
|
||||
keyFile.set_boolean ("GUI", "HideTPVScrollbar", hideTPVScrollbar);
|
||||
keyFile.set_boolean ("GUI", "UseIconNoText", UseIconNoText);
|
||||
|
||||
//Glib::ArrayHandle<int> crvopen = crvOpen;
|
||||
//keyFile.set_integer_list ("GUI", "CurvePanelsExpanded", crvopen);
|
||||
|
@@ -155,6 +155,7 @@ class Options {
|
||||
bool squareDetailWindow;
|
||||
bool FileBrowserToolbarSingleRow;
|
||||
bool hideTPVScrollbar;
|
||||
bool UseIconNoText;
|
||||
|
||||
bool menuGroupRank;
|
||||
bool menuGroupLabel;
|
||||
|
@@ -436,11 +436,21 @@ Gtk::Widget* Preferences::getGeneralPanel () {
|
||||
|
||||
Gtk::HBox* hbworkflow3 = Gtk::manage( new Gtk::HBox () );
|
||||
ckbFileBrowserToolbarSingleRow = Gtk::manage( new Gtk::CheckButton (M("PREFERENCES_FILEBROWSERTOOLBARSINGLEROW")) );
|
||||
|
||||
hbworkflow3->pack_start (*ckbFileBrowserToolbarSingleRow, Gtk::PACK_SHRINK, 4);
|
||||
vbworkflow->pack_start (*hbworkflow3, Gtk::PACK_SHRINK, 0);
|
||||
|
||||
Gtk::HBox* hbworkflow4 = Gtk::manage( new Gtk::HBox () );
|
||||
|
||||
Gtk::Label* hb4label = Gtk::manage( new Gtk::Label (M("PREFERENCES_TP_LABEL")) );
|
||||
hbworkflow4->pack_start (*hb4label, Gtk::PACK_SHRINK, 4);
|
||||
ckbHideTPVScrollbar = Gtk::manage( new Gtk::CheckButton (M("PREFERENCES_TP_VSCROLLBAR")) );
|
||||
vbworkflow->pack_start (*ckbHideTPVScrollbar, Gtk::PACK_SHRINK, 4);
|
||||
hbworkflow4->pack_start (*ckbHideTPVScrollbar, Gtk::PACK_SHRINK, 4);
|
||||
|
||||
ckbUseIconNoText = Gtk::manage( new Gtk::CheckButton (M("PREFERENCES_TP_USEICONORTEXT")) );
|
||||
hbworkflow4->pack_start (*ckbUseIconNoText, Gtk::PACK_SHRINK, 4);
|
||||
|
||||
vbworkflow->pack_start (*hbworkflow4, Gtk::PACK_SHRINK, 4);
|
||||
|
||||
fworklflow->add (*vbworkflow);
|
||||
mvbsd->pack_start (*fworklflow, Gtk::PACK_SHRINK, 4);
|
||||
@@ -1042,6 +1052,7 @@ void Preferences::storePreferences () {
|
||||
moptions.FileBrowserToolbarSingleRow = ckbFileBrowserToolbarSingleRow->get_active();
|
||||
moptions.hideTPVScrollbar = ckbHideTPVScrollbar->get_active();
|
||||
moptions.overwriteOutputFile = chOverwriteOutputFile->get_active ();
|
||||
moptions.UseIconNoText = ckbUseIconNoText->get_active();
|
||||
|
||||
// Sounds
|
||||
moptions.sndEnable = ckbSndEnable->get_active ();
|
||||
@@ -1155,6 +1166,7 @@ void Preferences::fillPreferences () {
|
||||
ckbSquareDetailWindow->set_active(moptions.squareDetailWindow);
|
||||
ckbFileBrowserToolbarSingleRow->set_active(moptions.FileBrowserToolbarSingleRow);
|
||||
ckbHideTPVScrollbar->set_active(moptions.hideTPVScrollbar);
|
||||
ckbUseIconNoText->set_active(moptions.UseIconNoText);
|
||||
|
||||
//darkFrameDir->set_filename( moptions.rtSettings.darkFramesPath );
|
||||
//updateDFinfos();
|
||||
@@ -1332,6 +1344,23 @@ void Preferences::workflowUpdate (){
|
||||
// Update the tool panels
|
||||
parent->updateTPVScrollbar (moptions.hideTPVScrollbar);
|
||||
}
|
||||
if(moptions.UseIconNoText != options.UseIconNoText) {
|
||||
// Update the tool's tab titles
|
||||
parent->updateTabsUsesIcons(moptions.UseIconNoText);
|
||||
}
|
||||
if(moptions.FileBrowserToolbarSingleRow != options.FileBrowserToolbarSingleRow) {
|
||||
// Update the position of the Query toolbar
|
||||
parent->updateFBQueryTB(moptions.FileBrowserToolbarSingleRow);
|
||||
}
|
||||
if(moptions.histogramPosition != options.histogramPosition) {
|
||||
// Update the position of the Histogram
|
||||
parent->updateHistogramPosition(options.histogramPosition, moptions.histogramPosition);
|
||||
}
|
||||
if(moptions.showProfileSelector != options.showProfileSelector) {
|
||||
// Update the position of the Profile selector
|
||||
parent->updateTPProfileSelector(moptions.showProfileSelector);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void Preferences::switchFontTo(Glib::ustring newFont) {
|
||||
|
@@ -134,6 +134,7 @@ class Preferences : public Gtk::Dialog {
|
||||
Gtk::CheckButton* ckbFileBrowserToolbarSingleRow;
|
||||
Gtk::CheckButton* ckbHideTPVScrollbar;
|
||||
Gtk::CheckButton* ckbSquareDetailWindow;
|
||||
Gtk::CheckButton* ckbUseIconNoText;
|
||||
|
||||
|
||||
Options moptions;
|
||||
|
@@ -466,6 +466,15 @@ void RTWindow::MoveFileBrowserToEditor()
|
||||
}
|
||||
}
|
||||
|
||||
void RTWindow::updateTPProfileSelector (bool showMe) {
|
||||
epanel->updateProfileSelector (showMe);
|
||||
|
||||
std::map<Glib::ustring, EditorPanel*>::const_iterator itr;
|
||||
for(itr = epanels.begin(); itr != epanels.end(); ++itr){
|
||||
((*itr).second)->updateProfileSelector (showMe);
|
||||
}
|
||||
}
|
||||
|
||||
void RTWindow::updateTPVScrollbar (bool hide) {
|
||||
fpanel->updateTPVScrollbar (hide);
|
||||
epanel->updateTPVScrollbar (hide);
|
||||
@@ -475,3 +484,26 @@ void RTWindow::updateTPVScrollbar (bool hide) {
|
||||
((*itr).second)->updateTPVScrollbar (hide);
|
||||
}
|
||||
}
|
||||
|
||||
void RTWindow::updateTabsUsesIcons (bool useIcons) {
|
||||
fpanel->updateTabsUsesIcons (useIcons);
|
||||
epanel->updateTabsUsesIcons (useIcons);
|
||||
|
||||
std::map<Glib::ustring, EditorPanel*>::const_iterator itr;
|
||||
for(itr = epanels.begin(); itr != epanels.end(); ++itr){
|
||||
((*itr).second)->updateTabsUsesIcons (useIcons);
|
||||
}
|
||||
}
|
||||
|
||||
void RTWindow::updateFBQueryTB (bool singleRow) {
|
||||
fpanel->fileCatalog->updateFBQueryTB (singleRow);
|
||||
}
|
||||
|
||||
void RTWindow::updateHistogramPosition (int oldPosition, int newPosition) {
|
||||
epanel->updateHistogramPosition (oldPosition, newPosition);
|
||||
|
||||
std::map<Glib::ustring, EditorPanel*>::const_iterator itr;
|
||||
for(itr = epanels.begin(); itr != epanels.end(); ++itr){
|
||||
((*itr).second)->updateHistogramPosition (oldPosition, newPosition);
|
||||
}
|
||||
}
|
||||
|
@@ -78,6 +78,10 @@ class RTWindow : public Gtk::Window, public rtengine::ProgressListener{
|
||||
void MoveFileBrowserToMain();
|
||||
|
||||
void updateTPVScrollbar (bool hide);
|
||||
void updateTPProfileSelector (bool showMe);
|
||||
void updateHistogramPosition (int oldPosition, int newPosition);
|
||||
void updateTabsUsesIcons (bool useIcons);
|
||||
void updateFBQueryTB (bool singleRow);
|
||||
bool getIsFullscreen() { return is_fullscreen; }
|
||||
};
|
||||
|
||||
|
@@ -148,48 +148,22 @@ ToolPanelCoordinator::ToolPanelCoordinator () : ipc(NULL) {
|
||||
rawPanel->pack_start (*Gtk::manage(new Gtk::HSeparator), Gtk::PACK_SHRINK,4);
|
||||
rawPanel->pack_start (*vbPanelEnd[4],Gtk::PACK_SHRINK,4);
|
||||
|
||||
TOITypes type = options.UseIconNoText ? TOI_ICON : TOI_TEXT;
|
||||
|
||||
Gtk::HBox* hbe = Gtk::manage (new Gtk::HBox ());
|
||||
hbe->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_EXPOSURE"))));
|
||||
hbe->set_spacing (2);
|
||||
hbe->set_tooltip_markup (M("MAIN_TAB_EXPOSURE_TOOLTIP"));
|
||||
hbe->show_all ();
|
||||
toolPanelNotebook->append_page (*exposurePanelSW, *hbe);
|
||||
toiE = Gtk::manage (new TextOrIcon (argv0+"/images/exposure-24.png" , M("MAIN_TAB_EXPOSURE") , M("MAIN_TAB_EXPOSURE_TOOLTIP") , type));
|
||||
toiD = Gtk::manage (new TextOrIcon (argv0+"/images/detail-24.png" , M("MAIN_TAB_DETAIL") , M("MAIN_TAB_DETAIL_TOOLTIP") , type));
|
||||
toiC = Gtk::manage (new TextOrIcon (argv0+"/images/colour-24.png" , M("MAIN_TAB_COLOR") , M("MAIN_TAB_COLOR_TOOLTIP") , type));
|
||||
toiT = Gtk::manage (new TextOrIcon (argv0+"/images/transform-24.png", M("MAIN_TAB_TRANSFORM"), M("MAIN_TAB_TRANSFORM_TOOLTIP"), type));
|
||||
toiR = Gtk::manage (new TextOrIcon (argv0+"/images/raw-24.png" , M("MAIN_TAB_RAW") , M("MAIN_TAB_RAW_TOOLTIP") , type));
|
||||
toiM = Gtk::manage (new TextOrIcon (argv0+"/images/exif-24.png" , M("MAIN_TAB_METADATA") , M("MAIN_TAB_METADATA_TOOLTIP") , type));
|
||||
|
||||
Gtk::HBox* hbd = Gtk::manage (new Gtk::HBox ());
|
||||
hbd->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_DETAIL"))));
|
||||
hbd->set_spacing (2);
|
||||
hbd->set_tooltip_markup (M("MAIN_TAB_DETAIL_TOOLTIP"));
|
||||
hbd->show_all ();
|
||||
toolPanelNotebook->append_page (*detailsPanelSW, *hbd);
|
||||
toolPanelNotebook->append_page (*exposurePanelSW, *toiE);
|
||||
toolPanelNotebook->append_page (*detailsPanelSW, *toiD);
|
||||
toolPanelNotebook->append_page (*colorPanelSW, *toiC);
|
||||
toolPanelNotebook->append_page (*transformPanelSW, *toiT);
|
||||
toolPanelNotebook->append_page (*rawPanelSW, *toiR);
|
||||
toolPanelNotebook->append_page (*metadataPanel, *toiM);
|
||||
|
||||
Gtk::HBox* hbc = Gtk::manage (new Gtk::HBox ());
|
||||
hbc->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_COLOR"))));
|
||||
hbc->set_spacing (2);
|
||||
hbc->set_tooltip_markup (M("MAIN_TAB_COLOR_TOOLTIP"));
|
||||
hbc->show_all ();
|
||||
toolPanelNotebook->append_page (*colorPanelSW, *hbc);
|
||||
|
||||
Gtk::HBox* hbt = Gtk::manage (new Gtk::HBox ());
|
||||
hbt->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_TRANSFORM"))));
|
||||
hbt->set_spacing (2);
|
||||
hbt->set_tooltip_markup (M("MAIN_TAB_TRANSFORM_TOOLTIP"));
|
||||
hbt->show_all ();
|
||||
toolPanelNotebook->append_page (*transformPanelSW, *hbt);
|
||||
|
||||
Gtk::HBox* hbr = Gtk::manage (new Gtk::HBox ());
|
||||
hbr->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_RAW"))));
|
||||
hbr->set_spacing (2);
|
||||
hbr->set_tooltip_markup (M("MAIN_TAB_RAW_TOOLTIP"));
|
||||
hbr->show_all ();
|
||||
toolPanelNotebook->append_page (*rawPanelSW, *hbr);
|
||||
|
||||
Gtk::HBox* hbm = Gtk::manage (new Gtk::HBox ());
|
||||
hbm->pack_start (*Gtk::manage (new Gtk::Label (M("MAIN_TAB_METADATA"))));
|
||||
hbm->set_spacing (2);
|
||||
hbm->set_tooltip_markup (M("MAIN_TAB_METADATA_TOOLTIP"));
|
||||
hbm->show_all ();
|
||||
toolPanelNotebook->append_page (*metadataPanel, *hbm);
|
||||
toolPanelNotebook->set_current_page (0);
|
||||
|
||||
toolPanelNotebook->set_scrollable ();
|
||||
@@ -549,9 +523,7 @@ bool ToolPanelCoordinator::handleShortcutKey (GdkEventKey* event) {
|
||||
toolPanelNotebook->set_current_page (toolPanelNotebook->page_num(*rawPanelSW));
|
||||
return true;
|
||||
case GDK_m:
|
||||
// !!! this should be improved by detecting if metadataPanel is present,
|
||||
// as this page is removed in BatchToolPanelCoordinator::BatchToolPanelCoordinator
|
||||
if (toolPanelNotebook->get_n_pages()==6){
|
||||
if (metadataPanel){
|
||||
toolPanelNotebook->set_current_page (toolPanelNotebook->page_num(*metadataPanel));
|
||||
return true;
|
||||
}
|
||||
@@ -569,6 +541,22 @@ void ToolPanelCoordinator::updateVScrollbars (bool hide) {
|
||||
rawPanelSW->set_policy (Gtk::POLICY_AUTOMATIC, policy);
|
||||
}
|
||||
|
||||
void ToolPanelCoordinator::updateTabsHeader (bool useIcons) {
|
||||
TOITypes type = useIcons ? TOI_ICON : TOI_TEXT;
|
||||
|
||||
toiE->switchTo(type);
|
||||
toiD->switchTo(type);
|
||||
toiC->switchTo(type);
|
||||
toiT->switchTo(type);
|
||||
toiR->switchTo(type);
|
||||
if (toiM)
|
||||
toiM->switchTo(type);
|
||||
}
|
||||
|
||||
void ToolPanelCoordinator::updateTPVScrollbar (bool hide) {
|
||||
updateVScrollbars (hide);
|
||||
}
|
||||
|
||||
void ToolPanelCoordinator::updateTabsUsesIcons (bool useIcons) {
|
||||
updateTabsHeader (useIcons);
|
||||
}
|
||||
|
@@ -120,6 +120,26 @@ class ToolPanelCoordinator : public ToolPanelListener,
|
||||
IPTCPanel* iptcpanel;
|
||||
ToolBar* toolBar;
|
||||
|
||||
TextOrIcon* toiE;
|
||||
TextOrIcon* toiD;
|
||||
TextOrIcon* toiC;
|
||||
TextOrIcon* toiT;
|
||||
TextOrIcon* toiR;
|
||||
TextOrIcon* toiM;
|
||||
|
||||
Gtk::Label* labelE;
|
||||
Gtk::Label* labelD;
|
||||
Gtk::Label* labelC;
|
||||
Gtk::Label* labelT;
|
||||
Gtk::Label* labelR;
|
||||
Gtk::Label* labelM;
|
||||
|
||||
Gtk::Image* imgIconE;
|
||||
Gtk::Image* imgIconD;
|
||||
Gtk::Image* imgIconC;
|
||||
Gtk::Image* imgIconT;
|
||||
Gtk::Image* imgIconR;
|
||||
Gtk::Image* imgIconM;
|
||||
Gtk::Image* imgPanelEnd[5];
|
||||
Gtk::VBox* vbPanelEnd[5];
|
||||
|
||||
@@ -136,6 +156,7 @@ class ToolPanelCoordinator : public ToolPanelListener,
|
||||
void addPanel (Gtk::Box* where, FoldableToolPanel* panel, Glib::ustring label);
|
||||
void foldThemAll (GdkEventButton* event);
|
||||
void updateVScrollbars (bool hide);
|
||||
void updateTabsHeader (bool useIcons);
|
||||
|
||||
public:
|
||||
|
||||
@@ -203,6 +224,7 @@ class ToolPanelCoordinator : public ToolPanelListener,
|
||||
CropGUIListener* startCropEditing (Thumbnail* thm=NULL) { return crop; }
|
||||
|
||||
void updateTPVScrollbar (bool hide);
|
||||
void updateTabsUsesIcons (bool useIcons);
|
||||
bool handleShortcutKey (GdkEventKey* event);
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user