[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - 3 commits - icon-themes/galaxy icon-themes/hicontrast svx/source

Caolán McNamara caolanm at redhat.com
Wed Jun 5 01:01:26 PDT 2013


 dev/null                                                     |binary
 icon-themes/hicontrast/svx/res/symphony/para_numbullet01.png |binary
 icon-themes/hicontrast/svx/res/symphony/para_numbullet02.png |binary
 svx/source/sidebar/paragraph/ParaPropertyPanel.cxx           |   28 +++++----
 svx/source/sidebar/paragraph/ParaPropertyPanel.hrc           |    4 -
 svx/source/sidebar/paragraph/ParaPropertyPanel.hxx           |    3 
 svx/source/sidebar/paragraph/ParaPropertyPanel.src           |   34 +++--------
 7 files changed, 29 insertions(+), 40 deletions(-)

New commits:
commit 84444da14de9261ef4cad99be53278202f941f0e
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jun 4 20:17:00 2013 +0100

    adjust para_numbullet icons for high-contrast themes
    
    Change-Id: I7bd91a345a2891b80b0997bccf3b7f42ff31c3da
    (cherry picked from commit 34c1b7bdd0bca4753f66a7d17ef46647a64a319e)

diff --git a/icon-themes/galaxy/svx/res/symphony/para_numbulleth01.png b/icon-themes/hicontrast/svx/res/symphony/para_numbullet01.png
similarity index 100%
rename from icon-themes/galaxy/svx/res/symphony/para_numbulleth01.png
rename to icon-themes/hicontrast/svx/res/symphony/para_numbullet01.png
diff --git a/icon-themes/galaxy/svx/res/symphony/para_numbulleth02.png b/icon-themes/hicontrast/svx/res/symphony/para_numbullet02.png
similarity index 100%
rename from icon-themes/galaxy/svx/res/symphony/para_numbulleth02.png
rename to icon-themes/hicontrast/svx/res/symphony/para_numbullet02.png
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx b/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
index 50d1b8c..d3af874 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
@@ -1591,7 +1591,6 @@ ParaPropertyPanel::ParaPropertyPanel(Window* pParent,
       maIndent3 (SVX_RES(IMG_INDENT3)),
       maIndHang (SVX_RES(IMG_INDENT_HANG)),
       maNumBImageList (SVX_RES(IL_NUM_BULLET)),
-      maNumBImageListH (SVX_RES(ILH_NUM_BULLET)),
       maNumBImageListRTL (SVX_RES(IL_NUM_BULLET_RTL)),
       maImgBackColorHigh (SVX_RES(IMG_BACK_COLOR_H)),
       maImgBackColor (SVX_RES(IMG_BACK_COLOR)),
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc b/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
index 7c0f46c..4d8fe96 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
@@ -57,7 +57,7 @@
 #define TBX_VERT_ALIGN      40
 #define TBX_NUM_BULLET      44
 #define IL_NUM_BULLET       45
-#define ILH_NUM_BULLET      46
+
 #define FT_BACK_COLOR       47
 #define TBX_BACK_COLOR      48
 #define TBI_BACK_COLOR      49
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx b/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
index 3903d6d..227a3c9 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
@@ -145,7 +145,6 @@ private:
     Image  maIndHang;
 
     ImageList   maNumBImageList;
-    ImageList   maNumBImageListH;
     ImageList   maNumBImageListRTL;
     Image       maImgBackColorHigh;
     Image       maImgBackColor;
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.src b/svx/source/sidebar/paragraph/ParaPropertyPanel.src
index e0504ce..6db5c75 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.src
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.src
@@ -419,12 +419,6 @@ Control RID_SIDEBAR_PARA_PANEL
         MaskColor = STD_MASKCOLOR ;
         SVX_PROPERTYPANEL_PARA_NUMBULLET_IDLIST
     };
-    ImageList ILH_NUM_BULLET
-    {
-        Prefix = "symphony/para_numbulleth";
-        MaskColor = STD_MASKCOLOR ;
-        SVX_PROPERTYPANEL_PARA_NUMBULLET_IDLIST
-    };
     //for sym2_7380
     ImageList IL_NUM_BULLET_RTL
     {
commit f27c78574e7f71c73b73bb4fd3c4a695e0ddc9f8
Author: Andre Fischer <af at apache.org>
Date:   Tue Jun 4 16:26:03 2013 +0000

    Related: #i122446# Removed unused icons
    
    (cherry picked from commit 98cb48c452fc49531b39af66e4db54211e8ffd9b)
    
    Conflicts:
    	icon-themes/galaxy/svx/res/symphony/DecreaseSpace_16x16.png
    	icon-themes/galaxy/svx/res/symphony/IncreaseSpace_16x16.png
    
    Change-Id: Ie159384031ee88b04d0a09bd0f6d95967845f253
    (cherry picked from commit 8d80d76b85ed76f3844a4a022d3184907009d79c)

diff --git a/icon-themes/galaxy/svx/res/symphony/DecreaseSpace_16x16.png b/icon-themes/galaxy/svx/res/symphony/DecreaseSpace_16x16.png
deleted file mode 100644
index 3f97e69..0000000
Binary files a/icon-themes/galaxy/svx/res/symphony/DecreaseSpace_16x16.png and /dev/null differ
diff --git a/icon-themes/galaxy/svx/res/symphony/IncreaseSpace_16x16.png b/icon-themes/galaxy/svx/res/symphony/IncreaseSpace_16x16.png
deleted file mode 100644
index f27f369..0000000
Binary files a/icon-themes/galaxy/svx/res/symphony/IncreaseSpace_16x16.png and /dev/null differ
commit 612924f24cb6cbcd688c28aecefee700840e2e96
Author: Andre Fischer <af at apache.org>
Date:   Tue Jun 4 16:24:18 2013 +0000

    Resolves: #i122446# Use different icons in Paragraph panel for...
    
    increasing or decreasing inter-paragraph spacing
    
    (cherry picked from commit 2dc77c47146c622ffbe37996c319000e55c2f697)
    
    Change-Id: I1f44c6a8a12853120016128975016572245c8981
    (cherry picked from commit 701afd6b82dc4b9caec4db42a2d06b8d04fc433a)

diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx b/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
index 88d29c9..50d1b8c 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.cxx
@@ -29,8 +29,10 @@
 #include <sfx2/sidebar/Theme.hxx>
 #include <sfx2/sidebar/ResourceDefinitions.hrc>
 #include <sfx2/sidebar/ControlFactory.hxx>
+#include <sfx2/sidebar/Tools.hxx>
 #include <svx/sidebar/PopupContainer.hxx>
 #include <sfx2/dispatch.hxx>
+//#include <sfx2/imagemgr.hxx>
 #include <editeng/colritem.hxx>
 #include <editeng/brushitem.hxx>
 #include <editeng/lrspitem.hxx>
@@ -49,9 +51,6 @@ using namespace cssu;
 using ::sfx2::sidebar::Theme;
 using ::sfx2::sidebar::ControlFactory;
 
-#define A2S(pString) (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(pString)))
-
-
 namespace svx {namespace sidebar {
 #define DEFAULT_VALUE          0
 #define TOOLBOX_ITEM1          1
@@ -65,8 +64,6 @@ namespace svx {namespace sidebar {
 #define INDENT_DECREMENT       2
 #define INDENT_STEP            706
 #define UL_STEP                58
-#define UL_INCREMENT           1
-#define UL_DECREMENT           2
 
 #define MAX_SW                  1709400
 #define MAX_SC_SD               116220200
@@ -474,8 +471,18 @@ void ParaPropertyPanel::InitToolBoxSpacing()
     maTopDist->SetAccessibleName(maTopDist->GetQuickHelpText());
     maBottomDist->SetAccessibleName(maBottomDist->GetQuickHelpText());
 
-    maTbxUL_IncDec->SetItemImage(TOOLBOX_ITEM1, maParInc);
-    maTbxUL_IncDec->SetItemImage(TOOLBOX_ITEM2, maParDec);
+    // Use a form of image loading that can handle both .uno:<command>
+    // and private:graphirepository... syntax.  This is necessary to
+    // handle the workaround for accessing the images of commands
+    // ParaspaceIncrease and ParaspaceDecrease.
+    // See issue 122446 for more details.
+    maTbxUL_IncDec->SetItemImage(
+        BT_TBX_UL_INC,
+        sfx2::sidebar::Tools::GetImage(maTbxUL_IncDec->GetItemCommand(BT_TBX_UL_INC), mxFrame));
+    maTbxUL_IncDec->SetItemImage(
+        BT_TBX_UL_DEC,
+        sfx2::sidebar::Tools::GetImage(maTbxUL_IncDec->GetItemCommand(BT_TBX_UL_DEC), mxFrame));
+
     aLink = LINK( this, ParaPropertyPanel, ClickUL_IncDec_Hdl_Impl );
     maTbxUL_IncDec->SetSelectHdl(aLink);
     m_eULSpaceUnit = maULSpaceControl.GetCoreMetric();
@@ -967,7 +974,7 @@ IMPL_LINK(ParaPropertyPanel, ClickUL_IncDec_Hdl_Impl, ToolBox *, pControl)
 {
     switch (pControl->GetCurItemId())
         {
-        case UL_INCREMENT:
+            case BT_TBX_UL_INC:
              {
                  SvxULSpaceItem aMargin( SID_ATTR_PARA_ULSPACE );
 
@@ -985,7 +992,7 @@ IMPL_LINK(ParaPropertyPanel, ClickUL_IncDec_Hdl_Impl, ToolBox *, pControl)
                      SID_ATTR_PARA_ULSPACE, SFX_CALLMODE_RECORD, &aMargin, 0L);
              }
              break;
-        case UL_DECREMENT:
+        case BT_TBX_UL_DEC:
             {
                  SvxULSpaceItem aMargin( SID_ATTR_PARA_ULSPACE );
 
@@ -1583,8 +1590,6 @@ ParaPropertyPanel::ParaPropertyPanel(Window* pParent,
       maIndent2 (SVX_RES(IMG_INDENT2)),
       maIndent3 (SVX_RES(IMG_INDENT3)),
       maIndHang (SVX_RES(IMG_INDENT_HANG)),
-      maParInc (SVX_RES(IMG_PARA_INC)),
-      maParDec (SVX_RES(IMG_PARA_DEC)),
       maNumBImageList (SVX_RES(IL_NUM_BULLET)),
       maNumBImageListH (SVX_RES(ILH_NUM_BULLET)),
       maNumBImageListRTL (SVX_RES(IL_NUM_BULLET_RTL)),
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc b/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
index 6ffb875..7c0f46c 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.hrc
@@ -34,8 +34,6 @@
 #define MF_AFTER_INDENT                              4
 #define MF_FL_INDENT                                 6
 #define TBX_HORIZONTALALIGNMENT                      5
-#define IMG_PARA_INC                                 13
-#define IMG_PARA_DEC                                 14
 #define IMG_INDENT_HANG                              15
 #define FT_INDENT                                    16
 #define TBX_INDENT_INC_DEC                           17
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx b/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
index 3ed393b..3903d6d 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.hxx
@@ -143,8 +143,6 @@ private:
     Image  maIndent3;
 
     Image  maIndHang;
-    Image  maParInc;
-    Image  maParDec;
 
     ImageList   maNumBImageList;
     ImageList   maNumBImageListH;
diff --git a/svx/source/sidebar/paragraph/ParaPropertyPanel.src b/svx/source/sidebar/paragraph/ParaPropertyPanel.src
index fd1b261..e0504ce 100644
--- a/svx/source/sidebar/paragraph/ParaPropertyPanel.src
+++ b/svx/source/sidebar/paragraph/ParaPropertyPanel.src
@@ -192,20 +192,24 @@ Control RID_SIDEBAR_PARA_PANEL
                 Identifier = BT_TBX_UL_INC ;
                 HelpID = HID_PPROPERTYPANEL_PARA_TBI_INC ;
                 Text [ en-US ] = "Increase Spacing" ;
-                ItemBitmap = Bitmap
-                {
-                    File = "symphony/IncreaseSpace_16x16.png";
-                };
+
+                /** The next line should be
+                    Command = ".uno:ParaspaceIncrease";
+                The hack is necessary because the ParaspaceIncrease command is only
+                defined for Draw/Impress.  It has to be defined in
+                GenericCommancs.xcu to be recognized. See issue 122446 for more details.
+                */
+                Command = "private:graphicrepository/res/commandimagelist/sc_paraspaceincrease.png";
             };
             ToolBoxItem
             {
                 Identifier = BT_TBX_UL_DEC ;
                 HelpID = HID_PPROPERTYPANEL_PARA_TBI_DEC ;
                 Text [ en-US ] = "Decrease Spacing" ;
-                ItemBitmap = Bitmap
-                {
-                    File = "symphony/DecreaseSpace_16x16.png";
-                };
+                /** See above or issue 122446 why the following line is not
+                    Command = ".uno:ParaspaceDecrease";
+                */
+                Command = "private:graphicrepository/res/commandimagelist/sc_paraspacedecrease.png";
             };
         };
     };
@@ -465,14 +469,6 @@ Control RID_SIDEBAR_PARA_PANEL
     {
         ImageBitmap = Bitmap{File = "symphony/Indent_Hanging.png";};
     };
-    Image IMG_PARA_INC
-    {
-        ImageBitmap = Bitmap{File = "symphony/IncreaseSpace_16x16.png";};
-    };
-    Image IMG_PARA_DEC
-    {
-        ImageBitmap = Bitmap{File = "symphony/DecreaseSpace_16x16.png";};
-    };
 };
 
 //===========================================Back color page==============================


More information about the Libreoffice-commits mailing list