Frank Schönheit - Sun Microsystems Germany wrote:
Hi Fernand,

The Xgrahpic object "getGraphFromStream" optained from the Second Function gives no "Image" in the ImageControlModel

In both cases i found (with Xray) the object in the ImageControlModel but see no reason why the first shows up and the second do not shows up ?????

Did you find the respective property, or was this property really
not-NULL? I.e., is the object returned from getGraphFromStream not-NULL?
If so, does XRay also tell you a valid Type property value of the
Graphic object? If so,
Xray gives me exactly the same property value's !!
does rendering the XGraphic into a device (using
an GraphicRenderer,
found this code on the forum: but  do not realy understand how it works:

i can not set  "setSourceDocument( ??????????????)" from my Graphicobject

and what is orenderer.render doing ?

sub Render
'oDialogControl = createUnoService( "com.sun.star.awt.UnoControlDialog" )
oRenderer = createUnoService("com.sun.star.graphic.GraphicRendererVCL")
Dim sRect as new com.sun.star.awt.Rectangle
sRect.X = 0
sRect.Y = 0
sRect.Width = 800
sRect.Height = 600 oRenderer.setPropertyValue("DestinationRect", sRect)
'the renderer shall paint to the dialog window
oDialogControl = Odialog.getControl("Foto2")
oRenderer.setPropertyValue("Device", oDialogControl.Peer.createGraphics.Device)

aArgs(0).Name  = "GraphicRenderer"
aArgs(0).Value = oRenderer

xExporter = createUnoService( "com.sun.star.drawing.GraphicExportFilter" )
'xExporter.setSourceDocument( ??????????????)

oPaintListener = CreateUnoListener("MyDialog_", "com.sun.star.awt.XPaintListener")

oDialogControl.Peer.addPaintListener( oPaintListener )
odialog.execute


'oDoc.close(true)
end sub


sub MyDialog_windowPaint(oEvt)
if oEvt.count > 0 then exit sub
xExporter.filter( aArgs() )
end sub

sub MyDialog_disposing(oEvt As Object)
end sub


sub MOD_modified(oEvt)
lModifyCount = lModifyCount + 1
end sub

sub MOD_disposing(oEvt As Object)
end sub
and perhaps a device you can obtain from, say, the
peer of the control) display anything?

Ciao
Frank


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

Reply via email to