summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorFrank Meies <fme@openoffice.org>2002-02-27 16:17:57 +0000
committerFrank Meies <fme@openoffice.org>2002-02-27 16:17:57 +0000
commitc605b04940e72f0ca43b10bd8f40301e479ad816 (patch)
treee9aa13b4ddfc6e86db3cf070a51d5c9a226759f9 /sw/source
parentc35f378c89a27a0fc94e32efd66819bf4ad411a3 (diff)
#95586# Accessibility - Get coordinates for a position inside a paragraph
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/text/txtfrm.cxx33
1 files changed, 31 insertions, 2 deletions
diff --git a/sw/source/core/text/txtfrm.cxx b/sw/source/core/text/txtfrm.cxx
index 1fe8a3b2cb01..1d7b53593a09 100644
--- a/sw/source/core/text/txtfrm.cxx
+++ b/sw/source/core/text/txtfrm.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: txtfrm.cxx,v $
*
- * $Revision: 1.30 $
+ * $Revision: 1.31 $
*
- * last change: $Author: fme $ $Date: 2002-02-19 15:05:39 $
+ * last change: $Author: fme $ $Date: 2002-02-27 17:17:57 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -363,6 +363,32 @@ SwFrmSwapper::~SwFrmSwapper()
#endif
+#ifdef BIDI
+void SwTxtFrm::SwitchRTLtoLTR( SwRect& rRect ) const
+{
+ long nWidth = rRect.Width();
+ rRect.Left( Frm().Left() + Frm().Right() - rRect.Right() );
+ rRect.Width( nWidth );
+}
+
+void SwTxtFrm::SwitchLTRtoRTL( SwRect& rRect ) const
+{
+ long nWidth = rRect.Width();
+ rRect.Left( 2 * Frm().Left() + Frm().Width() - rRect.Left() - rRect.Width() );
+ rRect.Width( nWidth );
+}
+
+void SwTxtFrm::SwitchLTRtoRTL( Point& rPoint ) const
+{
+ rPoint.X() = 2 * Frm().Left() + Frm().Width() - rPoint.X();
+}
+
+void SwTxtFrm::SwitchRTLtoLTR( Point& rPoint ) const
+{
+ rPoint.X() = 2 * Frm().Left() + Frm().Width() - rPoint.X();
+}
+#endif
+
/*************************************************************************
* SwTxtFrm::Init()
*************************************************************************/
@@ -2259,6 +2285,9 @@ void SwTxtFrm::VisitPortions( SwPortionHandler& rPH ) const
if( pPara )
{
+ if ( IsFollow() )
+ rPH.Skip( GetOfst() );
+
const SwLineLayout* pLine = pPara;
while ( pLine )
{