To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=76752


User pitonyak changed the following:

                What    |Old value                 |New value
================================================================================
                      CC|''                        |'pitonyak'
--------------------------------------------------------------------------------




------- Additional comments from [EMAIL PROTECTED] Sun Nov  4 20:13:42 +0000 
2007 -------
First of all, you do not declare your variables. OK, it works fine, but it
really bothers me...

Does this version work for you?

Sub LigneBrisee_new()
        Dim monDocument As Object, maPage As Object
        Dim maForme As Object
        Dim lesPoints(4) As New com.sun.star.awt.Point  
        monDocument = thisComponent
        monTexte = monDocument.Text
        monCurseur = monTexte.createTextCursor  
        maPage = monDocument.DrawPage
        maForme = 
monDocument.createInstance("com.sun.star.drawing.PolyLineShape")
        maForme.AnchorType = com.sun.star.text.TextContentAnchorType.AT_PAGE
        maForme.HoriOrientRelation = com.sun.star.text.RelOrientation.FRAME
        maForme.VertOrientRelation = com.sun.star.text.RelOrientation.FRAME
        lesPoints(0).X =  2100 : lesPoints(0).Y =  2100
        lesPoints(1).X =  4500 : lesPoints(1).Y =  4000
        lesPoints(2).X = 2200  : lesPoints(2).Y = 3000
        lesPoints(3).X = 2500  : lesPoints(3).Y = 4000
        lesPoints(4).X = 4000  : lesPoints(4).Y =  4000
        
        monTexte.insertTextContent(monCurseur, maForme, false)
        
        maForme.LineWidth = 80
        maForme.PolyPolygon = Array(lesPoints())

        
        Print maForme.VertOrientPosition
'       maForme.VertOrientRelation = 0 'relative to page area
'       maForme.HoriOrientRelation = 0 'relative to page area


        Print maForme.HoriOrientPosition                
        maForme2 = 
monDocument.createInstance("com.sun.star.drawing.PolyLineShape")
        maForme2.AnchorType = com.sun.star.text.TextContentAnchorType.AT_PAGE
        maForme2.HoriOrientRelation = com.sun.star.text.RelOrientation.FRAME
        maForme2.VertOrientRelation = com.sun.star.text.RelOrientation.FRAME
        lesPoints(0).X =  2000 : lesPoints(0).Y =  2000
        lesPoints(1).X =  3000 : lesPoints(1).Y =  2500
        lesPoints(2).X = 2500  : lesPoints(2).Y = 3000
        lesPoints(3).X = 3000  : lesPoints(3).Y = 6000
        lesPoints(4).X = 4000  : lesPoints(4).Y =  4000
        monTexte.insertTextContent(monCurseur, maForme2, false)
        maForme2.LineWidth = 60
        maForme2.PolyPolygon = Array(lesPoints())
        Print maForme2.VertOrientPosition
'       maForme2.VertOrientRelation = 0 'relative to page area
'       maForme2.HoriOrientRelation = 0 'relative to page area
        Print maForme2.HoriOrientPosition       
End Sub


---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to