Hmmm... I guess that explains that. IF you look at the canvas code in the…
To see the lines (it can be of help):
lazarus\lcl\interfaces\gtk\gtkobject.inc
Lines: 229, 231, 2151, 2186
lazarus\lcl\graphics.pp
Line: 346

Mailing lists / lazarus / 2000-11
5 messages · 3 people ·
Reply by email Subscribe to this list Your subscription
Read-only archive. Use j and k to move between messages.
Hmmm... I guess that explains that. IF you look at the canvas code in the…
To see the lines (it can be of help):
lazarus\lcl\interfaces\gtk\gtkobject.inc
Lines: 229, 231, 2151, 2186
lazarus\lcl\graphics.pp
Line: 346
Try Canvas.Pixels[500,475] := clRed; Shane It worked well, but Canvas.Line(To) he is…
It does not work. :(
FPC 1.0.x Windows
with Form1 do
begin
Canvas.pen.style := psSolid;
Canvas.pen.color := $FF0000; //clRed;
Canvas.Line(0,0,150,150);
Canvas.Pixels[151,151] := clRed; // Error
end;LM_SCREENINIT called --> should go to GTKObject.Init TODO: check this
Gtk-CRITICAL **: file gtkobject.c: line 1080 (gtk_object_get_data): assertion `GTK_IS_OBJECT (object)' failed.
Gdk-CRITICAL **: file gdkimage-win32.c: line 326 (gdk_image_get): assertion `window != NULL' failed.
Gdk-CRITICAL **: file gdkimage-win32.c: line 594 (gdk_image_put_pixel): assertion `image != NULL' failed.
Gtk-CRITICAL **: file gtkobject.c: line 1034 (gtk_object_set_data): assertion `GTK_IS_OBJECT (object)' failed.
Gtk-CRITICAL **: file gtkobject.c: line 1080 (gtk_object_get_data): assertion `GTK_IS_OBJECT (object)' failed.
An unhandled exception occurred at 0x00409E7F :
Access violation
0x00409E7F
0x0274FA0C
[TgtkObject.Destroy] WARNING: There are 12 unreleased DCs and 44 unreleased GDIObjects
[TgtkObject.Destroy] WARNING: There are 1 messages left in the queue! I'll free them
Try
Canvas.Pixels[500,475] := clRed;Shane
>> 11/01/00 10:27AM >>>
It worked well, but Canvas.Line(To) he is slower than to put only a pixel.
I want something like PutPixel() in Pascal.
Thanks!
Hmmm... I guess that explains that.
IF you look at the canvas code in the lazarus/lcl/include directory in canvas.inc you'll see there's a SetPixel function that uses CNSendMessage to send a command to the gtkint.pp "module". IF you go into gtkobject.inc and trace the message sent by the CNSendMessage you can see what, if anything, it is doing.
I'm not sure how easy it is to implement (I haven't looked at it) but I don't imagine it would be too tough.
Is this something you would like to try and look at Luis? It could be a good intro to Lazarus programming.... ????
Shane
>> 11/01/00 04:53PM >>>
This is not implemented (yet)
Marc
_________________________________________________________________ To unsubscribe: mail with
"unsubscribe" as the Subject
archives at http://www.miraclec.com/list_archives/lazarus
Try Canvas.Pixels[500,475] := clRed; Shane It worked well, but Canvas.Line(To) he is…
This is not implemented (yet)
Marc