From 289502bbdea92258327f01b302083a3f3a5ddc50 Mon Sep 17 00:00:00 2001 From: Philippe Hupe Date: Tue, 8 Nov 2011 20:30:51 +0100 Subject: [PATCH] In the histogram panel, each icon is changed depending on the activation status of each button. Moreover, the Value button is made insensitive when the Raw button is on (issue 1095). Patch optimised by Hombre --- rtdata/images/Dark/actions/histBar.png | Bin 0 -> 285 bytes rtdata/images/Dark/actions/histBarg.png | Bin 0 -> 298 bytes rtdata/images/Dark/actions/histBlue.png | Bin 0 -> 200 bytes rtdata/images/Dark/actions/histBlueg.png | Bin 0 -> 227 bytes rtdata/images/Dark/actions/histGreen.png | Bin 0 -> 200 bytes rtdata/images/Dark/actions/histGreeng.png | Bin 0 -> 232 bytes rtdata/images/Dark/actions/histRaw.png | Bin 0 -> 359 bytes rtdata/images/Dark/actions/histRawg.png | Bin 0 -> 344 bytes rtdata/images/Dark/actions/histRed.png | Bin 0 -> 200 bytes rtdata/images/Dark/actions/histRedg.png | Bin 0 -> 231 bytes rtdata/images/Dark/actions/histValue.png | Bin 0 -> 200 bytes rtdata/images/Dark/actions/histValueg.png | Bin 0 -> 237 bytes rtdata/images/Light/actions/histBar.png | Bin 0 -> 278 bytes rtdata/images/Light/actions/histBarg.png | Bin 0 -> 284 bytes rtdata/images/Light/actions/histBlue.png | Bin 0 -> 200 bytes rtdata/images/Light/actions/histBlueg.png | Bin 0 -> 227 bytes rtdata/images/Light/actions/histGreen.png | Bin 0 -> 200 bytes rtdata/images/Light/actions/histGreeng.png | Bin 0 -> 232 bytes rtdata/images/Light/actions/histRaw.png | Bin 0 -> 359 bytes rtdata/images/Light/actions/histRawg.png | Bin 0 -> 344 bytes rtdata/images/Light/actions/histRed.png | Bin 0 -> 200 bytes rtdata/images/Light/actions/histRedg.png | Bin 0 -> 231 bytes rtdata/images/Light/actions/histValue.png | Bin 0 -> 200 bytes rtdata/images/Light/actions/histValueg.png | Bin 0 -> 232 bytes rtgui/histogrampanel.cc | 123 +++- rtgui/histogrampanel.h | 22 + tools/source_icons/scalable/beforeafter.svg | 32 +- tools/source_icons/scalable/histBar.file | 1 + tools/source_icons/scalable/histBar.svg | 587 ++++++++++++++++++ tools/source_icons/scalable/histBarg.file | 1 + tools/source_icons/scalable/histBarg.svg | 555 +++++++++++++++++ tools/source_icons/scalable/histBlue.file | 1 + tools/source_icons/scalable/histBlue.svg | 494 +++++++++++++++ tools/source_icons/scalable/histBlueg.file | 1 + tools/source_icons/scalable/histBlueg.svg | 494 +++++++++++++++ tools/source_icons/scalable/histGreen.file | 1 + tools/source_icons/scalable/histGreen.svg | 494 +++++++++++++++ tools/source_icons/scalable/histGreeng.file | 1 + tools/source_icons/scalable/histGreeng.svg | 494 +++++++++++++++ tools/source_icons/scalable/histRaw.file | 1 + tools/source_icons/scalable/histRaw.svg | 632 ++++++++++++++++++++ tools/source_icons/scalable/histRawg.file | 1 + tools/source_icons/scalable/histRawg.svg | 615 +++++++++++++++++++ tools/source_icons/scalable/histRed.file | 1 + tools/source_icons/scalable/histRed.svg | 494 +++++++++++++++ tools/source_icons/scalable/histRedg.file | 1 + tools/source_icons/scalable/histRedg.svg | 494 +++++++++++++++ tools/source_icons/scalable/histValue.file | 1 + tools/source_icons/scalable/histValue.svg | 494 +++++++++++++++ tools/source_icons/scalable/histValueg.file | 1 + tools/source_icons/scalable/histValueg.svg | 494 +++++++++++++++ 51 files changed, 6468 insertions(+), 62 deletions(-) create mode 100644 rtdata/images/Dark/actions/histBar.png create mode 100644 rtdata/images/Dark/actions/histBarg.png create mode 100644 rtdata/images/Dark/actions/histBlue.png create mode 100644 rtdata/images/Dark/actions/histBlueg.png create mode 100644 rtdata/images/Dark/actions/histGreen.png create mode 100644 rtdata/images/Dark/actions/histGreeng.png create mode 100644 rtdata/images/Dark/actions/histRaw.png create mode 100644 rtdata/images/Dark/actions/histRawg.png create mode 100644 rtdata/images/Dark/actions/histRed.png create mode 100644 rtdata/images/Dark/actions/histRedg.png create mode 100644 rtdata/images/Dark/actions/histValue.png create mode 100644 rtdata/images/Dark/actions/histValueg.png create mode 100644 rtdata/images/Light/actions/histBar.png create mode 100644 rtdata/images/Light/actions/histBarg.png create mode 100644 rtdata/images/Light/actions/histBlue.png create mode 100644 rtdata/images/Light/actions/histBlueg.png create mode 100644 rtdata/images/Light/actions/histGreen.png create mode 100644 rtdata/images/Light/actions/histGreeng.png create mode 100644 rtdata/images/Light/actions/histRaw.png create mode 100644 rtdata/images/Light/actions/histRawg.png create mode 100644 rtdata/images/Light/actions/histRed.png create mode 100644 rtdata/images/Light/actions/histRedg.png create mode 100644 rtdata/images/Light/actions/histValue.png create mode 100644 rtdata/images/Light/actions/histValueg.png create mode 100644 tools/source_icons/scalable/histBar.file create mode 100644 tools/source_icons/scalable/histBar.svg create mode 100644 tools/source_icons/scalable/histBarg.file create mode 100644 tools/source_icons/scalable/histBarg.svg create mode 100644 tools/source_icons/scalable/histBlue.file create mode 100644 tools/source_icons/scalable/histBlue.svg create mode 100644 tools/source_icons/scalable/histBlueg.file create mode 100644 tools/source_icons/scalable/histBlueg.svg create mode 100644 tools/source_icons/scalable/histGreen.file create mode 100644 tools/source_icons/scalable/histGreen.svg create mode 100644 tools/source_icons/scalable/histGreeng.file create mode 100644 tools/source_icons/scalable/histGreeng.svg create mode 100644 tools/source_icons/scalable/histRaw.file create mode 100644 tools/source_icons/scalable/histRaw.svg create mode 100644 tools/source_icons/scalable/histRawg.file create mode 100644 tools/source_icons/scalable/histRawg.svg create mode 100644 tools/source_icons/scalable/histRed.file create mode 100644 tools/source_icons/scalable/histRed.svg create mode 100644 tools/source_icons/scalable/histRedg.file create mode 100644 tools/source_icons/scalable/histRedg.svg create mode 100644 tools/source_icons/scalable/histValue.file create mode 100644 tools/source_icons/scalable/histValue.svg create mode 100644 tools/source_icons/scalable/histValueg.file create mode 100644 tools/source_icons/scalable/histValueg.svg diff --git a/rtdata/images/Dark/actions/histBar.png b/rtdata/images/Dark/actions/histBar.png new file mode 100644 index 0000000000000000000000000000000000000000..afb574938221bd17f2e1c0d9c51a7f910dc91717 GIT binary patch literal 285 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprToxE{-7* zQ?H&ff4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprYlTE{-7* zQ`ZJq^EEk$%&GNokxDj`mg>^=+;h6@Jwuqxapi)Baxt&px*2EMu6c0mHVaz8+Zya^ zH2IAC(kUBQw+IQIta^TGTmI?QG5qJgF6~HJy)W7~>b3X7zdzT#xOnC4liI>dQTJVz zBtL6qI3O|kxWw!CJ0y~GdrsOfGB5wL-mt|$_~Hj;AzsB6$%^%9&s<%0E#CTDEA&7^ n%G==H#}f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F>sWejHoN#>Q62_U6IU|Nl>kOG-+-dtq!~aOUVj4z@`%Kg?+1IWn^&;K%_W mFbEOZr{Z+i+bxM%h9U8pi1-%kpq)Si89ZJ6T-G@yGywpM)IUT3 literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histBlueg.png b/rtdata/images/Dark/actions/histBlueg.png new file mode 100644 index 0000000000000000000000000000000000000000..69567180c6fc97f871e9e84603dcf62ac3b33314 GIT binary patch literal 227 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprQm%7sn8Z zsaq#(f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F>s;9P3ug#>Q62_U6IU`ltWJB_-b(yf8K}ICFF%2iv5XA7-@h9GTe>aO40G l7=(!IQ*pZM?UuwW!;o}HL|iQSNHx$v22WQ%mvv4FO#pmWKD7V< literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histGreeng.png b/rtdata/images/Dark/actions/histGreeng.png new file mode 100644 index 0000000000000000000000000000000000000000..39ab3e55840cb07fade8716897f5f43369237806 GIT binary patch literal 232 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprTYy7sn8Z zsar2>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprR+9E{-7* zQ>R|o=yxcA;mF7M+(=KmLjmE3+?cq}J3M;wK>CM-4a53JM;@HgF41b)p)i?~hfT}K zbGB7T@8W;UPd_c19`ht}m6^<%(Eja7FY+6Xx?H{8r97?kmcZsGN$uJDIoPY0m|i|o z6|hrf_vh2ctL>_?gnn|YVS63?JLcNjAkmF86Vj%zvAP})I@r}_a8gCsEFhD*Mw53^zVWa=?|VIehMq=w{j0ny4^i-+Viql7EKMN zinrHTG6j!tUYu05Dks#W{eQum5GTQI9ec*-D#1>k4&vEB|1x;G`njxgN@xNAQ)7@` literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histRawg.png b/rtdata/images/Dark/actions/histRawg.png new file mode 100644 index 0000000000000000000000000000000000000000..ea8838072a74077cee2821d3f7aae9a0b8a3bf39 GIT binary patch literal 344 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprWguE{-7* zQ>RW?n8oZU;(C5sSIRX} z<$Rc3p2U2FZF{|<*;1w-q5YGuoDZ*j?eys6$HJ{P@9w4>Ew5j7+Wi(!^V1Ci%A!35 iMy=6CHTfle`xtzjN;+9nElhwOWbkzLb6Mw<&;$VVV}io~ literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histRed.png b/rtdata/images/Dark/actions/histRed.png new file mode 100644 index 0000000000000000000000000000000000000000..1b7ad670674ab7f78eeba4ed83c5e67897710120 GIT binary patch literal 200 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F=IJ>*iL=#>Q62_U6ITPyhdmOTITScwuZ{aOUVj4z@`%Kg?+1IWn^&;K%_W lFbEOZr{Z+i+bxM%h9P;Lh&byH`C6cX44$rjF6*2UngE?_KKlRw literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histRedg.png b/rtdata/images/Dark/actions/histRedg.png new file mode 100644 index 0000000000000000000000000000000000000000..c46e4b38f69f29dad61130b5ef708ae35f3a641b GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprRB{7sn8Z zsar1`ZI#tQf|I9jA$@YbH0=p`E U?kBlHXxUHx3vIVCg!0AylL@&Et; literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histValue.png b/rtdata/images/Dark/actions/histValue.png new file mode 100644 index 0000000000000000000000000000000000000000..a40fdd8af8bece5629a7781c54fae70cb9721691 GIT binary patch literal 200 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F=Ip&$hZpLPA1CazpcTJw3hW66NpjkPX`*v;OXk;vd$@?2>=39JLdoZ literal 0 HcmV?d00001 diff --git a/rtdata/images/Dark/actions/histValueg.png b/rtdata/images/Dark/actions/histValueg.png new file mode 100644 index 0000000000000000000000000000000000000000..9167bdd2e6318531c7b045d2c4db43cbcf0e4297 GIT binary patch literal 237 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprR~K7sn8Z zsaq#(fPMLMaVS1&``Nw^dM!sndhO7#TE)Uz*>)d_)w!ElZDe9eLXmNIK zrIYb(*Aym|a`({UwWX}5v@^ckGZ&mG`M|4cHp8jCs_lG#&S#`q8`%BWapR^`)BDaB Z4CM{_?6c&4-2mFk;OXk;vd$@?2>|l*P9^{V literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histBar.png b/rtdata/images/Light/actions/histBar.png new file mode 100644 index 0000000000000000000000000000000000000000..2e88e6c1c248bbd9dfc092f6c4391e10b07445a0 GIT binary patch literal 278 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprXm1E{-7* zQ?H&fYjts9FM9^&^g3q)aP!nc75HF zRT;Opl^M#lZ8{^bep4)RV@&&Btz)0pW$G<^|JyM2nbd(o#Z8_KyHh5;_F)fY7K~=x zVYu0wA>vQkWKK?o5Bi2a6^dW)m7jUzw&)eJP3D4~m9wWCYPlR_+EMj>xBiC@=JPJx Ss5AyTkHOQ`&t;ucLK6Uo literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histBarg.png b/rtdata/images/Light/actions/histBarg.png new file mode 100644 index 0000000000000000000000000000000000000000..4139cd3c0c2ea7f039fc963fe97d6b0894203bb9 GIT binary patch literal 284 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprVST8vzp?9GCa19htCEz?w^Hx$WdL z$5l3ZOqy|~@MX*+J-v_W`-|84H2gRo&X6Y7E^w~$w%q*ov)W%@7VLi($?-5PZR!$3 zCXKEn-XAj^>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F>sWejHoN#>Q62_U6IU|Nl>kOG-+-dtq!~aOUVj4z@`%Kg?+1IWn^&;K%_W mFbEOZr{Z+i+bxM%h9U8pi1-%kpq)Si89ZJ6T-G@yGywpM)IUT3 literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histBlueg.png b/rtdata/images/Light/actions/histBlueg.png new file mode 100644 index 0000000000000000000000000000000000000000..69567180c6fc97f871e9e84603dcf62ac3b33314 GIT binary patch literal 227 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprQm%7sn8Z zsaq#(f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F>s;9P3ug#>Q62_U6IU`ltWJB_-b(yf8K}ICFF%2iv5XA7-@h9GTe>aO40G l7=(!IQ*pZM?UuwW!;o}HL|iQSNHx$v22WQ%mvv4FO#pmWKD7V< literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histGreeng.png b/rtdata/images/Light/actions/histGreeng.png new file mode 100644 index 0000000000000000000000000000000000000000..39ab3e55840cb07fade8716897f5f43369237806 GIT binary patch literal 232 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprTYy7sn8Z zsar2>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprR+9E{-7* zQ>R|o=yxcA;mF7M+(=KmLjmE3+?cq}J3M;wK>CM-4a53JM;@HgF41b)p)i?~hfT}K zbGB7T@8W;UPd_c19`ht}m6^<%(Eja7FY+6Xx?H{8r97?kmcZsGN$uJDIoPY0m|i|o z6|hrf_vh2ctL>_?gnn|YVS63?JLcNjAkmF86Vj%zvAP})I@r}_a8gCsEFhD*Mw53^zVWa=?|VIehMq=w{j0ny4^i-+Viql7EKMN zinrHTG6j!tUYu05Dks#W{eQum5GTQI9ec*-D#1>k4&vEB|1x;G`njxgN@xNAQ)7@` literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histRawg.png b/rtdata/images/Light/actions/histRawg.png new file mode 100644 index 0000000000000000000000000000000000000000..ea8838072a74077cee2821d3f7aae9a0b8a3bf39 GIT binary patch literal 344 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprWguE{-7* zQ>RW?n8oZU;(C5sSIRX} z<$Rc3p2U2FZF{|<*;1w-q5YGuoDZ*j?eys6$HJ{P@9w4>Ew5j7+Wi(!^V1Ci%A!35 iMy=6CHTfle`xtzjN;+9nElhwOWbkzLb6Mw<&;$VVV}io~ literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histRed.png b/rtdata/images/Light/actions/histRed.png new file mode 100644 index 0000000000000000000000000000000000000000..1b7ad670674ab7f78eeba4ed83c5e67897710120 GIT binary patch literal 200 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F=IJ>*iL=#>Q62_U6ITPyhdmOTITScwuZ{aOUVj4z@`%Kg?+1IWn^&;K%_W lFbEOZr{Z+i+bxM%h9P;Lh&byH`C6cX44$rjF6*2UngE?_KKlRw literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histRedg.png b/rtdata/images/Light/actions/histRedg.png new file mode 100644 index 0000000000000000000000000000000000000000..c46e4b38f69f29dad61130b5ef708ae35f3a641b GIT binary patch literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprRB{7sn8Z zsar1`ZI#tQf|I9jA$@YbH0=p`E U?kBlHXxUHx3vIVCg!0AylL@&Et; literal 0 HcmV?d00001 diff --git a/rtdata/images/Light/actions/histValue.png b/rtdata/images/Light/actions/histValue.png new file mode 100644 index 0000000000000000000000000000000000000000..f30f35a7b2435d32bcb7122366f401a35b8c4a01 GIT binary patch literal 200 zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXpdwdK7sn8Z zsmXu-|F>_RHEWh2Gjp>FbJ>SK*VaZqmk13F?Uj&_nD#h;g?XY+g^v^4Bp(-zqy!+4 l(Bhgeyzrf+@f4u@pObhHwBu4M$1`kk47*5m^kR zl|h*C>KCzCAVadmHKHUqKdq!Zu_%?Hyu4g5GcUV1Ik6yBFTW^#_B$IXprTYy7sn8Z zsaq#(E6_p)Pgg&ebxsLQ0G2~fVE_OC literal 0 HcmV?d00001 diff --git a/rtgui/histogrampanel.cc b/rtgui/histogrampanel.cc index fd60637db..51aa13a7b 100644 --- a/rtgui/histogrampanel.cc +++ b/rtgui/histogrampanel.cc @@ -41,14 +41,21 @@ HistogramPanel::HistogramPanel () { histogramRGBArea->setParent(gfxVBox); gfxVBox->pack_start (*histogramArea, Gtk::PACK_EXPAND_WIDGET, 0); if (options.histogramBar) - gfxVBox->pack_start (*histogramRGBArea, Gtk::PACK_SHRINK, 0); + gfxVBox->pack_start (*histogramRGBArea, Gtk::PACK_SHRINK, 0); - Gtk::Image* redImage = Gtk::manage( new RTImage ("histRed.png") ); - Gtk::Image* greenImage = Gtk::manage( new RTImage ("histGreen.png") ); - Gtk::Image* blueImage = Gtk::manage( new RTImage ("histBlue.png") ); - Gtk::Image* valueImage = Gtk::manage( new RTImage ("histValue.png") ); - Gtk::Image* rawImage = Gtk::manage( new RTImage ("histRaw.png") ); - Gtk::Image* barImage = Gtk::manage( new RTImage ("histBar.png") ); + redImage = new RTImage ("histRed.png"); + greenImage = new RTImage ("histGreen.png"); + blueImage = new RTImage ("histBlue.png"); + valueImage = new RTImage ("histValue.png"); + rawImage = new RTImage ("histRaw.png"); + barImage = new RTImage ("histBar.png"); + + redImage_g = new RTImage ("histRedg.png"); + greenImage_g = new RTImage ("histGreeng.png"); + blueImage_g = new RTImage ("histBlueg.png"); + valueImage_g = new RTImage ("histValueg.png"); + rawImage_g = new RTImage ("histRawg.png"); + barImage_g = new RTImage ("histBarg.png"); showRed = Gtk::manage (new Gtk::ToggleButton ()); showGreen = Gtk::manage (new Gtk::ToggleButton ()); @@ -57,12 +64,12 @@ HistogramPanel::HistogramPanel () { showRAW = Gtk::manage (new Gtk::ToggleButton ()); showBAR = Gtk::manage (new Gtk::ToggleButton ()); - showRed->set_name("histButton"); - showGreen->set_name("histButton"); - showBlue->set_name("histButton"); - showValue->set_name("histButton"); - showRAW->set_name("histButton"); - showBAR->set_name("histButton"); + showRed->set_name("histButton"); showRed->set_can_focus(false); + showGreen->set_name("histButton"); showGreen->set_can_focus(false); + showBlue->set_name("histButton"); showBlue->set_can_focus(false); + showValue->set_name("histButton"); showValue->set_can_focus(false); + showRAW->set_name("histButton"); showRAW->set_can_focus(false); + showBAR->set_name("histButton"); showBAR->set_can_focus(false); showRed->set_relief (Gtk::RELIEF_NONE); showGreen->set_relief (Gtk::RELIEF_NONE); @@ -71,13 +78,6 @@ HistogramPanel::HistogramPanel () { showRAW->set_relief (Gtk::RELIEF_NONE); showBAR->set_relief (Gtk::RELIEF_NONE); - showRed->set_image(*redImage); - showGreen->set_image(*greenImage); - showBlue->set_image(*blueImage); - showValue->set_image(*valueImage); - showRAW->set_image(*rawImage); - showBAR->set_image(*barImage); - showRed->set_tooltip_text (M("HISTOGRAM_TOOLTIP_R")); showGreen->set_tooltip_text (M("HISTOGRAM_TOOLTIP_G")); showBlue->set_tooltip_text (M("HISTOGRAM_TOOLTIP_B")); @@ -93,12 +93,22 @@ HistogramPanel::HistogramPanel () { showRAW->set_active (false); showBAR->set_active (options.histogramBar); - showRed->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); - showGreen->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); - showBlue->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); - showValue->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); - showRAW->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); - showBAR->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::rgbv_toggled) ); + showRed->set_image(*redImage); + showGreen->set_image(*greenImage); + showBlue->set_image(*blueImage); + showValue->set_image(*valueImage); + showRAW->set_image(*rawImage_g); + if (showBAR->get_active()) + showBAR->set_image(*barImage); + else + showBAR->set_image(*barImage_g); + + showRed->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::red_toggled), showRed ); + showGreen->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::green_toggled), showGreen ); + showBlue->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::blue_toggled), showBlue ); + showValue->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::value_toggled), showValue ); + showRAW->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::raw_toggled), showRAW ); + showBAR->signal_toggled().connect( sigc::mem_fun(*this, &HistogramPanel::bar_toggled), showBAR ); buttonVBox->pack_start (*showRed, Gtk::PACK_SHRINK, 0); buttonVBox->pack_start (*showGreen, Gtk::PACK_SHRINK, 0); @@ -122,6 +132,22 @@ HistogramPanel::HistogramPanel () { rconn = signal_size_allocate().connect( sigc::mem_fun(*this, &HistogramPanel::resized) ); } +HistogramPanel::~HistogramPanel () { + delete redImage; + delete greenImage; + delete blueImage; + delete valueImage; + delete rawImage; + delete barImage; + + delete redImage_g; + delete greenImage_g; + delete blueImage_g; + delete valueImage_g; + delete rawImage_g; + delete barImage_g; +} + void HistogramPanel::resized (Gtk::Allocation& req) { rconn.block (true); @@ -153,8 +179,41 @@ void HistogramPanel::resized (Gtk::Allocation& req) { } } -void HistogramPanel::rgbv_toggled () { +void HistogramPanel::red_toggled () { + showRed->set_image(showRed->get_active() ? *redImage : *redImage_g); + rgbv_toggled(); +} +void HistogramPanel::green_toggled () { + showGreen->set_image(showGreen->get_active() ? *greenImage : *greenImage_g); + rgbv_toggled(); +} +void HistogramPanel::blue_toggled () { + showBlue->set_image(showBlue->get_active() ? *blueImage : *blueImage_g); + rgbv_toggled(); +} +void HistogramPanel::value_toggled () { + removeIfThere(showValue, valueImage, false); + removeIfThere(showValue, valueImage_g, false); + showValue->set_image(showValue->get_active() ? *valueImage : *valueImage_g); + rgbv_toggled(); +} +void HistogramPanel::raw_toggled () { + if (showRAW->get_active()) { + showRAW->set_image(*rawImage); + showValue->set_sensitive(false); + } + else { + showRAW->set_image(*rawImage_g); + showValue->set_sensitive(true); + } + rgbv_toggled(); +} +void HistogramPanel::bar_toggled () { + showBAR->set_image(showBAR->get_active() ? *barImage : *barImage_g); + rgbv_toggled(); +} +void HistogramPanel::rgbv_toggled () { // Update Display histogramArea->updateOptions (showRed->get_active(), showGreen->get_active(), showBlue->get_active(), showValue->get_active(), showRAW->get_active()); histogramArea->queue_draw (); @@ -211,7 +270,7 @@ void HistogramPanel::reorder (Gtk::AlignmentEnum align) { // // HistogramRGBArea HistogramRGBArea::HistogramRGBArea () : - frozen(false), valid(false), needRed(true), needGreen(true), needBlue(true), needLuma(true), rawMode(false), showMode(options.histogramBar) { + frozen(false), valid(false), needRed(true), needGreen(true), needBlue(true), needLuma(true), rawMode(false), showMode(options.histogramBar), barDisplayed(options.histogramBar) { harih = new HistogramRGBAreaIdleHelper; harih->harea = this; @@ -355,19 +414,21 @@ void HistogramRGBArea::updateOptions (bool r, bool g, bool b, bool l, bool raw, needBlue = b; needLuma = l; rawMode = raw; - showMode = bar; + showMode = bar; // Histogram RGB BAR button logic goes here - if (bar) { + if (bar && !barDisplayed) { // Toggled on, add (show) the widget parent->pack_start(*this, Gtk::PACK_SHRINK, 0); options.histogramBar = true; + barDisplayed = true; } - else { + else if (!bar && barDisplayed){ // Toggled off, remove (hide) the widget removeIfThere(parent, this, false); options.histogramBar = false; + barDisplayed = false; // unfreeze updateFreeze(false); } diff --git a/rtgui/histogrampanel.h b/rtgui/histogrampanel.h index e6dfee4b2..d63239586 100644 --- a/rtgui/histogrampanel.h +++ b/rtgui/histogrampanel.h @@ -70,6 +70,7 @@ class HistogramRGBArea : public Gtk::DrawingArea { bool needLuma; bool rawMode; bool showMode; + bool barDisplayed; Gtk::VBox* parent; @@ -158,12 +159,27 @@ class HistogramPanel : public Gtk::HBox, public PointerMotionListener { Gtk::ToggleButton* showRAW; Gtk::ToggleButton* showBAR; + Gtk::Image *redImage; + Gtk::Image *greenImage; + Gtk::Image *blueImage; + Gtk::Image *valueImage; + Gtk::Image *rawImage; + Gtk::Image *barImage; + Gtk::Image *redImage_g; + Gtk::Image *greenImage_g; + Gtk::Image *blueImage_g; + Gtk::Image *valueImage_g; + Gtk::Image *rawImage_g; + Gtk::Image *barImage_g; + + sigc::connection rconn; void setHistInvalid (); public: HistogramPanel (); + ~HistogramPanel (); void histogramChanged (LUTu &histRed, LUTu &histGreen, LUTu &histBlue, LUTu &histLuma, LUTu &histRedRaw, LUTu &histGreenRaw, LUTu &histBlueRaw) { histogramArea->update (histRed, histGreen, histBlue, histLuma, histRedRaw, histGreenRaw, histBlueRaw); @@ -176,6 +192,12 @@ class HistogramPanel : public Gtk::HBox, public PointerMotionListener { void setHistRGBInvalid (); void reorder (Gtk::AlignmentEnum align); + void red_toggled (); + void green_toggled (); + void blue_toggled (); + void value_toggled (); + void raw_toggled (); + void bar_toggled (); void rgbv_toggled (); void resized (Gtk::Allocation& req); }; diff --git a/tools/source_icons/scalable/beforeafter.svg b/tools/source_icons/scalable/beforeafter.svg index 4497d0e5d..0e45b9d06 100644 --- a/tools/source_icons/scalable/beforeafter.svg +++ b/tools/source_icons/scalable/beforeafter.svg @@ -461,7 +461,7 @@ inkscape:pageshadow="2" inkscape:zoom="0.45544553" inkscape:cx="-259.32616" - inkscape:cy="606.79299" + inkscape:cy="1221.5756" inkscape:document-units="px" inkscape:current-layer="g4060" showguides="true" @@ -517,36 +517,6 @@ style="opacity:0.8;fill:#2a7fff;fill-opacity:1;fill-rule:nonzero;stroke:none" d="m -48.396035,-116.06278 -218.472655,0 c -0.72062,0 -1.30599,0.5854 -1.30599,1.30599 l 0,448.80283 c -7e-5,0.72058 0.58537,1.30598 1.30599,1.30598 l 374.03,0 c 0.72055,0 1.28525,-0.5854 1.28525,-1.30598 l 0,-148.59209 -32.193569,0 0,119.44582 c 0,0.62694 -0.49247,1.11941 -1.119416,1.11941 l -309.974535,0 c -0.62694,0 -1.14015,-0.49247 -1.14015,-1.11941 l 0,-390.489559 c 0,-0.626945 0.51321,-1.140145 1.14015,-1.140145 l 186.444925,0 0,-29.332846 z" id="path4557" /> - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histBarg.file b/tools/source_icons/scalable/histBarg.file new file mode 100644 index 000000000..248cd289e --- /dev/null +++ b/tools/source_icons/scalable/histBarg.file @@ -0,0 +1 @@ +histBarg.png,w10 diff --git a/tools/source_icons/scalable/histBarg.svg b/tools/source_icons/scalable/histBarg.svg new file mode 100644 index 000000000..a1cec3797 --- /dev/null +++ b/tools/source_icons/scalable/histBarg.svg @@ -0,0 +1,555 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histBlue.file b/tools/source_icons/scalable/histBlue.file new file mode 100644 index 000000000..007abf73b --- /dev/null +++ b/tools/source_icons/scalable/histBlue.file @@ -0,0 +1 @@ +histBlue.png,w10 diff --git a/tools/source_icons/scalable/histBlue.svg b/tools/source_icons/scalable/histBlue.svg new file mode 100644 index 000000000..129c708e9 --- /dev/null +++ b/tools/source_icons/scalable/histBlue.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histBlueg.file b/tools/source_icons/scalable/histBlueg.file new file mode 100644 index 000000000..a2af682a2 --- /dev/null +++ b/tools/source_icons/scalable/histBlueg.file @@ -0,0 +1 @@ +histBlueg.png,w10 diff --git a/tools/source_icons/scalable/histBlueg.svg b/tools/source_icons/scalable/histBlueg.svg new file mode 100644 index 000000000..ab0b32804 --- /dev/null +++ b/tools/source_icons/scalable/histBlueg.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histGreen.file b/tools/source_icons/scalable/histGreen.file new file mode 100644 index 000000000..1170d414c --- /dev/null +++ b/tools/source_icons/scalable/histGreen.file @@ -0,0 +1 @@ +histGreen.png,w10 diff --git a/tools/source_icons/scalable/histGreen.svg b/tools/source_icons/scalable/histGreen.svg new file mode 100644 index 000000000..0c8babc4d --- /dev/null +++ b/tools/source_icons/scalable/histGreen.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histGreeng.file b/tools/source_icons/scalable/histGreeng.file new file mode 100644 index 000000000..37d41af88 --- /dev/null +++ b/tools/source_icons/scalable/histGreeng.file @@ -0,0 +1 @@ +histGreeng.png,w10 diff --git a/tools/source_icons/scalable/histGreeng.svg b/tools/source_icons/scalable/histGreeng.svg new file mode 100644 index 000000000..c85a8d412 --- /dev/null +++ b/tools/source_icons/scalable/histGreeng.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histRaw.file b/tools/source_icons/scalable/histRaw.file new file mode 100644 index 000000000..7565bc25a --- /dev/null +++ b/tools/source_icons/scalable/histRaw.file @@ -0,0 +1 @@ +histRaw.png,w10 diff --git a/tools/source_icons/scalable/histRaw.svg b/tools/source_icons/scalable/histRaw.svg new file mode 100644 index 000000000..73fa612ce --- /dev/null +++ b/tools/source_icons/scalable/histRaw.svg @@ -0,0 +1,632 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histRawg.file b/tools/source_icons/scalable/histRawg.file new file mode 100644 index 000000000..fc0864248 --- /dev/null +++ b/tools/source_icons/scalable/histRawg.file @@ -0,0 +1 @@ +histRawg.png,w10 diff --git a/tools/source_icons/scalable/histRawg.svg b/tools/source_icons/scalable/histRawg.svg new file mode 100644 index 000000000..69fac8f10 --- /dev/null +++ b/tools/source_icons/scalable/histRawg.svg @@ -0,0 +1,615 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histRed.file b/tools/source_icons/scalable/histRed.file new file mode 100644 index 000000000..d8f6aeeb1 --- /dev/null +++ b/tools/source_icons/scalable/histRed.file @@ -0,0 +1 @@ +histRed.png,w10 diff --git a/tools/source_icons/scalable/histRed.svg b/tools/source_icons/scalable/histRed.svg new file mode 100644 index 000000000..fdff14a74 --- /dev/null +++ b/tools/source_icons/scalable/histRed.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histRedg.file b/tools/source_icons/scalable/histRedg.file new file mode 100644 index 000000000..267755a1c --- /dev/null +++ b/tools/source_icons/scalable/histRedg.file @@ -0,0 +1 @@ +histRedg.png,w10 diff --git a/tools/source_icons/scalable/histRedg.svg b/tools/source_icons/scalable/histRedg.svg new file mode 100644 index 000000000..c25dba5c2 --- /dev/null +++ b/tools/source_icons/scalable/histRedg.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histValue.file b/tools/source_icons/scalable/histValue.file new file mode 100644 index 000000000..aecd59611 --- /dev/null +++ b/tools/source_icons/scalable/histValue.file @@ -0,0 +1 @@ +histValue.png,w10 diff --git a/tools/source_icons/scalable/histValue.svg b/tools/source_icons/scalable/histValue.svg new file mode 100644 index 000000000..b82f4da01 --- /dev/null +++ b/tools/source_icons/scalable/histValue.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/tools/source_icons/scalable/histValueg.file b/tools/source_icons/scalable/histValueg.file new file mode 100644 index 000000000..6879914e7 --- /dev/null +++ b/tools/source_icons/scalable/histValueg.file @@ -0,0 +1 @@ +histValueg.png,w10 diff --git a/tools/source_icons/scalable/histValueg.svg b/tools/source_icons/scalable/histValueg.svg new file mode 100644 index 000000000..ffc0daaf8 --- /dev/null +++ b/tools/source_icons/scalable/histValueg.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + +