summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--editeng/source/items/borderline.cxx11
-rw-r--r--editeng/source/items/frmitems.cxx2
-rw-r--r--offapi/com/sun/star/table/BorderLineStyle.idl8
-rw-r--r--svtools/inc/svtools/ctrlbox.hxx1
-rw-r--r--svtools/source/control/ctrlbox.cxx7
5 files changed, 27 insertions, 2 deletions
diff --git a/editeng/source/items/borderline.cxx b/editeng/source/items/borderline.cxx
index 1904916f832d..646a3480724c 100644
--- a/editeng/source/items/borderline.cxx
+++ b/editeng/source/items/borderline.cxx
@@ -128,9 +128,11 @@ ConvertBorderStyleFromWord(int const nWordLineStyle)
return DOTTED;
break;
case 7:
- case 22:
return DASHED;
break;
+ case 22:
+ return FINE_DASHED;
+ break;
// then the shading beams which we represent by a double line
case 23:
return DOUBLE;
@@ -216,6 +218,10 @@ ConvertBorderWidthFromWord(SvxBorderStyle const eStyle, double const fWidth,
case DOTTED:
case DASHED:
return fWidth;
+
+ // Display a minimum effective border width of 1pt
+ case FINE_DASHED:
+ return (fWidth > 0 && fWidth < 20) ? 20 : fWidth;
break;
// Double lines
@@ -270,6 +276,7 @@ ConvertBorderWidthToWord(SvxBorderStyle const eStyle, double const fWidth)
case SOLID:
case DOTTED:
case DASHED:
+ case FINE_DASHED:
return fWidth;
break;
@@ -335,6 +342,7 @@ BorderWidthImpl SvxBorderLine::getWidthImpl( SvxBorderStyle nStyle )
case SOLID:
case DOTTED:
case DASHED:
+ case FINE_DASHED:
aImpl = BorderWidthImpl( CHANGE_LINE1, 1.0 );
break;
@@ -514,6 +522,7 @@ void SvxBorderLine::GuessLinesWidths( SvxBorderStyle nStyle, sal_uInt16 nOut, sa
case SOLID:
case DOTTED:
case DASHED:
+ case FINE_DASHED:
::std::swap( nOut, nIn);
break;
default:
diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx
index 6f410c64a08f..5ee12a8b6139 100644
--- a/editeng/source/items/frmitems.cxx
+++ b/editeng/source/items/frmitems.cxx
@@ -1794,7 +1794,7 @@ sal_Bool
SvxBoxItem::LineToSvxLine(const ::com::sun::star::table::BorderLine2& rLine, SvxBorderLine& rSvxLine, sal_Bool bConvert)
{
SvxBorderStyle const nStyle =
- (rLine.LineStyle < 0 || INSET < rLine.LineStyle)
+ (rLine.LineStyle < 0 || BORDER_LINE_STYLE_MAX < rLine.LineStyle)
? SOLID // default
: rLine.LineStyle;
diff --git a/offapi/com/sun/star/table/BorderLineStyle.idl b/offapi/com/sun/star/table/BorderLineStyle.idl
index 0007118eed7f..7613272043d1 100644
--- a/offapi/com/sun/star/table/BorderLineStyle.idl
+++ b/offapi/com/sun/star/table/BorderLineStyle.idl
@@ -90,6 +90,14 @@ constants BorderLineStyle
/** Inset border line.
*/
const short INSET = 13;
+
+ /** Finely dashed border line.
+ */
+ const short FINE_DASHED = 14;
+
+ /** Maximum valid border line style value.
+ */
+ const short BORDER_LINE_STYLE_MAX = 14;
};
diff --git a/svtools/inc/svtools/ctrlbox.hxx b/svtools/inc/svtools/ctrlbox.hxx
index a6b26b8a5a05..2d6e6a2536d9 100644
--- a/svtools/inc/svtools/ctrlbox.hxx
+++ b/svtools/inc/svtools/ctrlbox.hxx
@@ -44,6 +44,7 @@ typedef ::std::vector< FontInfo > ImplFontList;
#define STYLE_SOLID ( ( sal_uInt16 ) 0 )
#define STYLE_DOTTED ( ( sal_uInt16 ) 1 )
#define STYLE_DASHED ( ( sal_uInt16 ) 2 )
+#define STYLE_FINE_DASHED ( ( sal_uInt16 ) 14 )
#define STYLE_NONE ( ( sal_uInt16 ) -1)
#define CHANGE_LINE1 ( ( sal_uInt16 ) 1 )
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index 017422f0ea75..dd739d40f509 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -615,6 +615,13 @@ namespace svtools
aPattern.push_back( 20 );
}
break;
+ case STYLE_FINE_DASHED:
+ if ( eUnit == MAP_PIXEL )
+ {
+ aPattern.push_back( 4 );
+ aPattern.push_back( 1 );
+ }
+ break;
default:
break;
}