From 07a5627d92719740b5f16fdd8d53926acfffbde6 Mon Sep 17 00:00:00 2001 From: Amelia Wang Date: Mon, 13 Sep 2010 14:42:43 +0200 Subject: cjk-character-units-rulers-sync-with-pggrid-fix.diff: --- svtools/inc/ruler.hxx | 2 ++ svtools/source/control/ruler.cxx | 12 ++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) (limited to 'svtools') diff --git a/svtools/inc/ruler.hxx b/svtools/inc/ruler.hxx index bcf441e5c2d2..3caa9cd6bccd 100644 --- a/svtools/inc/ruler.hxx +++ b/svtools/inc/ruler.hxx @@ -876,6 +876,8 @@ public: void SetCharWidth( long nWidth ) { mnCharWidth = nWidth ; } void SetLineHeight( long nHeight ) { mnLineHeight = nHeight ; } + + void DrawTicks(); }; #endif // _RULER_HXX diff --git a/svtools/source/control/ruler.cxx b/svtools/source/control/ruler.cxx index 9897c96e1672..92c33e988c84 100644 --- a/svtools/source/control/ruler.cxx +++ b/svtools/source/control/ruler.cxx @@ -476,14 +476,14 @@ void Ruler::ImplDrawTicks( long nMin, long nMax, long nStart, long nCenter ) long nTick2 ; if ( mnUnitIndex == RULER_UNIT_CHAR ) { - nTick3 = mnCharWidth; + nTick3 = mnCharWidth*2; nTickCount = mnCharWidth; nTickUnit = mnCharWidth; nTick2 = mnCharWidth; } else if ( mnUnitIndex == RULER_UNIT_LINE ) { - nTick3 = mnLineHeight; + nTick3 = mnLineHeight*2; nTickCount = mnLineHeight; nTickUnit = mnLineHeight; nTick2 = mnLineHeight; @@ -3219,3 +3219,11 @@ const RulerBorder* Ruler::GetBorders() const { return mpData->pBorders; } USHORT Ruler::GetIndentCount() const { return mpData->nIndents; } const RulerIndent* Ruler::GetIndents() const { return mpData->pIndents; } +/* --------------------------------------------------- + * + * ---------------------------------------------------*/ +void Ruler::DrawTicks() +{ + mbFormat = TRUE; + ImplDraw(); +} -- cgit v1.2.3