Hunting for bugs in OXT 0.98 and above

Any Bug Fixes to OpenXTalk should get listed here so we can keep a list and offer thanks to contributors!
User avatar
tperry2x
Posts: 1581
Joined: Tue Dec 21, 2021 9:10 pm
Location: Britain (Previously known as Great Britain)
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by tperry2x »

I think it's good to retain the paint tools. Even if many people don't use them, it could be handy just for marking something for the attention of someone. (Like drawing an arrow or annotation).

I've also made the new paint image that is created sit behind everything (move to back), so that if any buttons are placed on the card, these aren't obscured or unclickable when the image is created.

paint-everywhere.png
paint-everywhere.png (74.55 KiB) Viewed 121 times
User avatar
richmond62
Posts: 2820
Joined: Sun Sep 12, 2021 11:03 am
Location: Bulgaria
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by richmond62 »

The paint tools would be extremely useful if you wanted to make a program like Apple's Freeform:
-
SShot 2024-04-23 at 15.33.10.png
SShot 2024-04-23 at 15.33.10.png (432.21 KiB) Viewed 116 times
-
And a Freeform rip-off that was cross-platform is not such a daft idea.
https://richmondmathewson.owlstown.net/
User avatar
tperry2x
Posts: 1581
Joined: Tue Dec 21, 2021 9:10 pm
Location: Britain (Previously known as Great Britain)
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by tperry2x »

richmond62 wrote: Tue Apr 23, 2024 12:34 pm And a Freeform rip-off that was cross-platform is not such a daft idea.
Now there's an idea - one for the fun & games section (or example stacks etc).
I've never tried the paint tools in LCC/OXT with a stylus and graphics tablet - I'll have to have a try at some point.
Failing that, if someone creates a stack - we can later export to android (easier of the two mobile platforms to publish for), and have it with a stylus on there... just ideas.
User avatar
OpenXTalkPaul
Posts: 1609
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by OpenXTalkPaul »

tperry2x wrote: Tue Apr 23, 2024 12:23 pm I think it's good to retain the paint tools. Even if many people don't use them, it could be handy just for marking something for the attention of someone. (Like drawing an arrow or annotation).

I've also made the new paint image that is created sit behind everything (move to back), so that if any buttons are placed on the card, these aren't obscured or unclickable when the image is created.


paint-everywhere.png
I was just thinking, and this is probably expensive for a cosmetic thing, Tools could swap the color table on the cursor image before loading it, so that way a brush shaped cursor would be filed with the selected paint color. I believe all Desktop OSes support color cursors nowadays. It would be cool to see the cursor in the color you're about to paint pixels with.
User avatar
tperry2x
Posts: 1581
Joined: Tue Dec 21, 2021 9:10 pm
Location: Britain (Previously known as Great Britain)
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by tperry2x »

I like that suggestion. This is picked up from the revCursors stack (and I believe there's a separate mac and linux stack, although it's debatable if they are actually used).
I initially thought it would be quite 'expensive' on the processor cycles and slow things down, as I supposed you'd have to have to set the colour, then have it export the image and reimport it.

But, then I remembered about this in the user guides:
To manipulate the binary data of an image, use the image's imageData property. This property returns the color and transparency value of each pixel in the image in a consistent format regardless of the format the image is saved in. The imageData is stored as binary, with each pixel represented by 4 bytes. To convert it to and from RGB values use the byteToNum and numToByte functions.

For example, the numeric value of the red, green and blue channels respectively for the tenth pixel are given by the expressions:

Code: Select all

   charToNum(char (4 * 9 + 2 of the imageData of image <image>)
   charToNum(char (4 * 9 + 3 of the imageData of image <image>)
   charToNum(char (4 * 9 + 4 of the imageData of image <image>)
So I thought we could colour individual live pixels of the cursor graphic directly this way then set the cursor to it, which would show a colour at the end of a brush for example.
User avatar
OpenXTalkPaul
Posts: 1609
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by OpenXTalkPaul »

richmond62 wrote: Tue Apr 23, 2024 12:34 pm The paint tools would be extremely useful if you wanted to make a program like Apple's Freeform:
-
SShot 2024-04-23 at 15.33.10.png
-
And a Freeform rip-off that was cross-platform is not such a daft idea.
Are you guys aware of the SVGPathDrawWidget I made a while back?
I thought I posted about it.
There's actually not (currently) that much to it but it works, simple and effective.
Kind of a white board thing that generates SVG paths as you draw on it.
It could be useful for this sort of use case.
SVGDrawWidgetPIcolors.jpg
SVGDrawWidgetPIcolors.jpg (71.87 KiB) Viewed 50 times
SVGDrawWidgetPI.jpg
SVGDrawWidgetPI.jpg (141.96 KiB) Viewed 50 times
You can delete the lines of the SVGPaths property to 'undo' any strokes that were drawn.

It's not all that 'eavy , it's a "wafer thin"!
User avatar
tperry2x
Posts: 1581
Joined: Tue Dec 21, 2021 9:10 pm
Location: Britain (Previously known as Great Britain)
Contact:

Re: Hunting for bugs in OXT 0.98 and above

Post by tperry2x »

No, I was not aware of that at all.
It somehow got past me :D
Do you have a link you can attach so we can try it out? Would be cool to add an SVG eraser tool, so it can remove points of the SVG that are clicked on or dragged over.
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests