I'm having trouble with the penColor in a graphic in a Datagrid row template
(LiveCode 6.6.2 Commercial)
In the onFillInData handler, I can set the WIDTH of the graphic with code like
set the width of grc "My_grc" of me to 15
However, this code
set the penColor of grc "My_grc" of me to 100,200,50
Fail silently. Does anyone know if I'm doing something wrong, if this isn't a capability of Datagrid, or I'm perhaps looking at a bug?
Thanks!
Bruce
Using a graphic in Datagrid row template
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: Using a graphic in Datagrid row template
Hi Bruce,
"penColor" is used with paint tools. I.e. when you paint (draw) into a bitmap image.
Apparently you are using a graphic object. You can set the "foregroundColor" of a graphic object to get the effect you are after.
Kind regards
Bernd
"penColor" is used with paint tools. I.e. when you paint (draw) into a bitmap image.
Apparently you are using a graphic object. You can set the "foregroundColor" of a graphic object to get the effect you are after.
Kind regards
Bernd
Re: Using a graphic in Datagrid row template
Bernd:
Aha! You've put your finger on it!
Actually, I was intending to use a LINE grc, but since I hadn't told LiveCode and was using default rectangle with an invisible line, all my work on the pen was invisible.
Oddly, making the appropriate changes to the graphic (declaring it as style 'Line') now seems to render it invisible, but the code works when I use a rectangle with a visible line.
So I've likely got some other snafu, but haven't investigated; I just wanted to write and say Thanks!
Bruce
Aha! You've put your finger on it!
Actually, I was intending to use a LINE grc, but since I hadn't told LiveCode and was using default rectangle with an invisible line, all my work on the pen was invisible.
Oddly, making the appropriate changes to the graphic (declaring it as style 'Line') now seems to render it invisible, but the code works when I use a rectangle with a visible line.
So I've likely got some other snafu, but haven't investigated; I just wanted to write and say Thanks!
Bruce
Re: Using a graphic in Datagrid row template
The line had no points, hence no visible representation.
So setting the grc to style 'Line' and giving it dimensions and all is well.
Thanks again, Bernd!
So setting the grc to style 'Line' and giving it dimensions and all is well.
Thanks again, Bernd!