Blame 0001-Resolves-tdf-49407-enable-CaseMap-property-in-impres.patch

6af1c7f
From fb65ac2e3028c4fc160a47448bc44d73d282c9f2 Mon Sep 17 00:00:00 2001
6af1c7f
From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= <caolanm@redhat.com>
6af1c7f
Date: Mon, 8 Jun 2015 12:21:01 +0100
6af1c7f
Subject: [PATCH] Resolves: tdf#49407 enable CaseMap property in impress/draw
6af1c7f
6af1c7f
I don't see why this was explicitly disabled, works fine
6af1c7f
out of the box for me, import/export already hooked up
6af1c7f
in odf
6af1c7f
6af1c7f
Change-Id: I5e6bdbc6a4f3cbcd97330c7d9fb33589489afee2
6af1c7f
---
6af1c7f
 cui/source/inc/chardlg.hxx      | 10 ----------
6af1c7f
 sd/sdi/drtxtob.sdi              |  6 ++++++
6af1c7f
 sd/source/core/typemap.cxx      |  1 +
6af1c7f
 sd/source/ui/dlg/dlgchar.cxx    |  1 -
6af1c7f
 sd/source/ui/dlg/prltempl.cxx   |  1 -
6af1c7f
 sd/source/ui/dlg/tabtempl.cxx   |  1 -
6af1c7f
 sd/source/ui/func/fuchar.cxx    |  1 +
6af1c7f
 sd/source/ui/func/futext.cxx    |  7 ++++---
6af1c7f
 sd/source/ui/view/drtxtob.cxx   |  3 ++-
6af1c7f
 sd/source/ui/view/drviews2.cxx  | 11 +++++++++++
6af1c7f
 sd/source/ui/view/drviewsf.cxx  |  1 +
6af1c7f
 sw/source/ui/chrdlg/chardlg.cxx |  8 +-------
6af1c7f
 12 files changed, 27 insertions(+), 24 deletions(-)
6af1c7f
6af1c7f
diff --git a/cui/source/inc/chardlg.hxx b/cui/source/inc/chardlg.hxx
6af1c7f
index 4eb009a..a023a45 100644
6af1c7f
--- a/cui/source/inc/chardlg.hxx
6af1c7f
+++ b/cui/source/inc/chardlg.hxx
6af1c7f
@@ -32,16 +32,6 @@
6af1c7f
 class SvxFontListItem;
6af1c7f
 class FontList;
6af1c7f
 
6af1c7f
-
6af1c7f
-
6af1c7f
-#define DISABLE_CASEMAP             ((sal_uInt16)0x0001)
6af1c7f
-#define DISABLE_WORDLINE            ((sal_uInt16)0x0002)
6af1c7f
-#define DISABLE_BLINK               ((sal_uInt16)0x0004)
6af1c7f
-#define DISABLE_UNDERLINE_COLOR     ((sal_uInt16)0x0008)
6af1c7f
-
6af1c7f
-#define DISABLE_LANGUAGE            ((sal_uInt16)0x0010)
6af1c7f
-#define DISABLE_HIDE_LANGUAGE       ((sal_uInt16)0x0020)
6af1c7f
-
6af1c7f
 // class SvxCharBasePage -------------------------------------------------
6af1c7f
 
6af1c7f
 class SvxCharBasePage : public SfxTabPage
6af1c7f
diff --git a/sd/sdi/drtxtob.sdi b/sd/sdi/drtxtob.sdi
6af1c7f
index 3e975d4..ed564e4 100644
6af1c7f
--- a/sd/sdi/drtxtob.sdi
6af1c7f
+++ b/sd/sdi/drtxtob.sdi
6af1c7f
@@ -92,6 +92,12 @@ shell TextObjectBar
6af1c7f
         StateMethod = GetAttrState;
6af1c7f
     ]
6af1c7f
 
6af1c7f
+    SID_ATTR_CHAR_CASEMAP   // ole : ?, status : ?
6af1c7f
+    [
6af1c7f
+        ExecMethod = Execute;
6af1c7f
+        StateMethod = GetAttrState;
6af1c7f
+    ]
6af1c7f
+
6af1c7f
     SID_ATTR_PARA_ADJUST_LEFT  // ole : ?, status : ?
6af1c7f
     [
6af1c7f
         ExecMethod = Execute;
6af1c7f
diff --git a/sd/source/core/typemap.cxx b/sd/source/core/typemap.cxx
6af1c7f
index a5548a3..65f7cf0 100644
6af1c7f
--- a/sd/source/core/typemap.cxx
6af1c7f
+++ b/sd/source/core/typemap.cxx
6af1c7f
@@ -21,6 +21,7 @@
6af1c7f
 
6af1c7f
 #include <editeng/outliner.hxx>
6af1c7f
 #include <editeng/eeitem.hxx>
6af1c7f
+#include <editeng/cmapitem.hxx>
6af1c7f
 #include <editeng/langitem.hxx>
6af1c7f
 #include <editeng/fhgtitem.hxx>
6af1c7f
 #include <editeng/colritem.hxx>
6af1c7f
diff --git a/sd/source/ui/dlg/dlgchar.cxx b/sd/source/ui/dlg/dlgchar.cxx
6af1c7f
index a23cd80..5e44899 100644
6af1c7f
--- a/sd/source/ui/dlg/dlgchar.cxx
6af1c7f
+++ b/sd/source/ui/dlg/dlgchar.cxx
6af1c7f
@@ -60,7 +60,6 @@ void SdCharDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
6af1c7f
     }
6af1c7f
     else if (nId == mnCharEffects)
6af1c7f
     {
6af1c7f
-        aSet.Put (SfxUInt16Item(SID_DISABLE_CTL,DISABLE_CASEMAP));
6af1c7f
         rPage.PageCreated(aSet);
6af1c7f
     }
6af1c7f
 }
6af1c7f
diff --git a/sd/source/ui/dlg/prltempl.cxx b/sd/source/ui/dlg/prltempl.cxx
6af1c7f
index 74c010e..c503c93 100644
6af1c7f
--- a/sd/source/ui/dlg/prltempl.cxx
6af1c7f
+++ b/sd/source/ui/dlg/prltempl.cxx
6af1c7f
@@ -281,7 +281,6 @@ void SdPresLayoutTemplateDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
6af1c7f
 
6af1c7f
     else if (nId == mnEffects)
6af1c7f
         {
6af1c7f
-            aSet.Put (SfxUInt16Item(SID_DISABLE_CTL,DISABLE_CASEMAP));
6af1c7f
             rPage.PageCreated(aSet);
6af1c7f
         }
6af1c7f
 }
6af1c7f
diff --git a/sd/source/ui/dlg/tabtempl.cxx b/sd/source/ui/dlg/tabtempl.cxx
6af1c7f
index 61514ee..1189922 100644
6af1c7f
--- a/sd/source/ui/dlg/tabtempl.cxx
6af1c7f
+++ b/sd/source/ui/dlg/tabtempl.cxx
6af1c7f
@@ -152,7 +152,6 @@ void SdTabTemplateDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
6af1c7f
     }
6af1c7f
     else if (nId == m_nFontEffectId)
6af1c7f
     {
6af1c7f
-        aSet.Put (SfxUInt16Item(SID_DISABLE_CTL,DISABLE_CASEMAP));
6af1c7f
         rPage.PageCreated(aSet);
6af1c7f
     }
6af1c7f
     else if (nId == m_nTextId)
6af1c7f
diff --git a/sd/source/ui/func/fuchar.cxx b/sd/source/ui/func/fuchar.cxx
6af1c7f
index 174391a..b8166c2 100644
6af1c7f
--- a/sd/source/ui/func/fuchar.cxx
6af1c7f
+++ b/sd/source/ui/func/fuchar.cxx
6af1c7f
@@ -106,6 +106,7 @@ void FuChar::DoExecute( SfxRequest& rReq )
6af1c7f
                     SID_ATTR_CHAR_FONTHEIGHT,
6af1c7f
                     SID_ATTR_CHAR_COLOR,
6af1c7f
                     SID_ATTR_CHAR_KERNING,
6af1c7f
+                    SID_ATTR_CHAR_CASEMAP,
6af1c7f
                     SID_SET_SUPER_SCRIPT,
6af1c7f
                     SID_SET_SUB_SCRIPT,
6af1c7f
                     0 };
6af1c7f
diff --git a/sd/source/ui/func/futext.cxx b/sd/source/ui/func/futext.cxx
6af1c7f
index ac6fb71..33e5339 100644
6af1c7f
--- a/sd/source/ui/func/futext.cxx
6af1c7f
+++ b/sd/source/ui/func/futext.cxx
6af1c7f
@@ -85,12 +85,13 @@ static sal_uInt16 SidArray[] = {
6af1c7f
     SID_ATTR_CHAR_FONT,               //   10007
6af1c7f
     SID_ATTR_CHAR_POSTURE,            //   10008
6af1c7f
     SID_ATTR_CHAR_WEIGHT,             //   10009
6af1c7f
-    SID_ATTR_CHAR_SHADOWED,     //10010
6af1c7f
-    SID_ATTR_CHAR_STRIKEOUT,        //10013
6af1c7f
+    SID_ATTR_CHAR_SHADOWED,           //   10010
6af1c7f
+    SID_ATTR_CHAR_STRIKEOUT,          //   10013
6af1c7f
     SID_ATTR_CHAR_UNDERLINE,          //   10014
6af1c7f
     SID_ATTR_CHAR_FONTHEIGHT,         //   10015
6af1c7f
     SID_ATTR_CHAR_COLOR,              //   10017
6af1c7f
-    SID_ATTR_CHAR_KERNING,          //10018
6af1c7f
+    SID_ATTR_CHAR_KERNING,            //   10018
6af1c7f
+    SID_ATTR_CHAR_CASEMAP,            //   10019
6af1c7f
     SID_ATTR_PARA_ADJUST_LEFT,        //   10028
6af1c7f
     SID_ATTR_PARA_ADJUST_RIGHT,       //   10029
6af1c7f
     SID_ATTR_PARA_ADJUST_CENTER,      //   10030
6af1c7f
diff --git a/sd/source/ui/view/drtxtob.cxx b/sd/source/ui/view/drtxtob.cxx
6af1c7f
index 25913dd..45c868f 100644
6af1c7f
--- a/sd/source/ui/view/drtxtob.cxx
6af1c7f
+++ b/sd/source/ui/view/drtxtob.cxx
6af1c7f
@@ -171,8 +171,9 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet )
6af1c7f
             case SID_ATTR_CHAR_FONTHEIGHT:
6af1c7f
             case SID_ATTR_CHAR_WEIGHT:
6af1c7f
             case SID_ATTR_CHAR_POSTURE:
6af1c7f
-        case SID_ATTR_CHAR_SHADOWED:
6af1c7f
+            case SID_ATTR_CHAR_SHADOWED:
6af1c7f
             case SID_ATTR_CHAR_STRIKEOUT:
6af1c7f
+            case SID_ATTR_CHAR_CASEMAP:
6af1c7f
             {
6af1c7f
                 sal_uInt16 stretchX = 100;
6af1c7f
                 sal_uInt16 stretchY = 100;
6af1c7f
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
6af1c7f
index d4ed8fa..ffbb503 100644
6af1c7f
--- a/sd/source/ui/view/drviews2.cxx
6af1c7f
+++ b/sd/source/ui/view/drviews2.cxx
6af1c7f
@@ -87,6 +87,7 @@
6af1c7f
 #include <vcl/svapp.hxx>
6af1c7f
 #include <vcl/waitobj.hxx>
6af1c7f
 
6af1c7f
+#include <editeng/cmapitem.hxx>
6af1c7f
 #include <editeng/escapementitem.hxx>
6af1c7f
 #include <editeng/kernitem.hxx>
6af1c7f
 #include <editeng/wghtitem.hxx>
6af1c7f
@@ -3032,6 +3033,16 @@ void DrawViewShell::ExecChar( SfxRequest &rReq )
6af1c7f
             }
6af1c7f
         }
6af1c7f
         break;
6af1c7f
+    case SID_ATTR_CHAR_CASEMAP:
6af1c7f
+        if( rReq.GetArgs() )
6af1c7f
+        {
6af1c7f
+            SFX_REQUEST_ARG( rReq, pItem, SvxCaseMapItem, SID_ATTR_CHAR_CASEMAP , false );
6af1c7f
+            if (pItem)
6af1c7f
+            {
6af1c7f
+                aNewAttr.Put(*pItem);
6af1c7f
+            }
6af1c7f
+        }
6af1c7f
+        break;
6af1c7f
     case SID_SET_SUB_SCRIPT:
6af1c7f
         {
6af1c7f
             SvxEscapementItem aItem( EE_CHAR_ESCAPEMENT );
6af1c7f
diff --git a/sd/source/ui/view/drviewsf.cxx b/sd/source/ui/view/drviewsf.cxx
6af1c7f
index 56d7a88..a5183c1 100644
6af1c7f
--- a/sd/source/ui/view/drviewsf.cxx
6af1c7f
+++ b/sd/source/ui/view/drviewsf.cxx
6af1c7f
@@ -409,6 +409,7 @@ void DrawViewShell::GetAttrState( SfxItemSet& rSet )
6af1c7f
             case SID_ATTR_CHAR_WEIGHT:
6af1c7f
             case SID_ATTR_CHAR_COLOR:
6af1c7f
             case SID_ATTR_CHAR_KERNING:
6af1c7f
+            case SID_ATTR_CHAR_CASEMAP:
6af1c7f
             case SID_SET_SUB_SCRIPT:
6af1c7f
             case SID_SET_SUPER_SCRIPT:
6af1c7f
             {
6af1c7f
diff --git a/sw/source/ui/chrdlg/chardlg.cxx b/sw/source/ui/chrdlg/chardlg.cxx
6af1c7f
index b20dfdc2..2483fda 100644
6af1c7f
--- a/sw/source/ui/chrdlg/chardlg.cxx
6af1c7f
+++ b/sw/source/ui/chrdlg/chardlg.cxx
6af1c7f
@@ -112,13 +112,7 @@ void SwCharDlg::PageCreated( sal_uInt16 nId, SfxTabPage &rPage )
6af1c7f
     }
6af1c7f
     else if (nId == m_nCharExtId)
6af1c7f
     {
6af1c7f
-        if(m_nDialogMode == DLG_CHAR_DRAW || m_nDialogMode == DLG_CHAR_ANN)
6af1c7f
-            aSet.Put (SfxUInt16Item(SID_DISABLE_CTL,DISABLE_CASEMAP));
6af1c7f
-
6af1c7f
-        else
6af1c7f
-        {
6af1c7f
-            aSet.Put (SfxUInt32Item(SID_FLAG_TYPE,SVX_PREVIEW_CHARACTER|SVX_ENABLE_FLASH));
6af1c7f
-        }
6af1c7f
+        aSet.Put (SfxUInt32Item(SID_FLAG_TYPE,SVX_PREVIEW_CHARACTER|SVX_ENABLE_FLASH));
6af1c7f
         rPage.PageCreated(aSet);
6af1c7f
     }
6af1c7f
     else if (nId == m_nCharPosId)
6af1c7f
-- 
6af1c7f
2.4.0
6af1c7f