Page 1 of 3

Serendipity Editors For Images & Icons

Posted: Sun Oct 03, 2021 12:02 am
by RCozens
My gift to the LiveCode community...
..with special thanks to members of the Talking LiveCode Forum.

Enjoy!

Re: Serendipity Editors Fot Images & Icons

Posted: Sun Oct 03, 2021 6:22 pm
by richmond62
SShot 2021-10-03 at 20.21.10.png
-
"agai"

You need to set fields so that they expand and contract to accommodate
the fonts on differing operating systems.

Re: Serendipity Editors Fot Images & Icons

Posted: Mon Oct 04, 2021 6:33 pm
by RCozens
The About message in Serendipity Editors requests users contact me privately with questions, bug reports, and comments.  In retrospect, it seems to me that questions, etc. are best posted to this entry in Built With LiveCode, where I will post fixes and replies.
Here are the first post-release issues:

1.  The Export Image button does not mask the image when selected with the right mouse button.  Fix--  Line 1 of the button's mouseDown handler is missing "e" as the final character.  It should read,

Code: Select all

 put mouse(3) into mouse3State 
2.  LiveCode's paint tools modify image "New Image Frame" if it is not totally covered by the image being edited.  Fix-- Add this line at the end of the Image Editor card script's fitStackToImage handler. 

Code: Select all

set the rectangle of image "New Image Frame" to the rectangle of image id imageIdNumber

(resize/reposition "New Image Frame" before exporting a snapshot encompassing multiple images.)

3.  Handlers to enable/disable certain buttons in groups Page Selector, Scan Image Pulldown, and Export Image Pulldown were disabling the groups but enabling the buttons.  Fixes--

Handler resetButtons of group Image Editor Controls

Code: Select all

set the disabled of button "Scan Image" of group "Scan Image Pulldown" to disableButtons
set the disabled of button "Export Image" of group "Export Image Pulldown" to disableButtons
Handler disableButtons of the Image Editor card script

Code: Select all

set the disabled of button "Scan Image" of group "Scan Image Pulldown" to false
set the disabled of button "Export Image" of group "Export Image Pulldown" to false 
set the disabled of button "Screen Selector" of group "Page Selector" to false

Handler enableButtons of the Image Editor card script

Code: Select all

set the disabled of button "Scan Image" of group "Scan Image Pulldown" to true
set the disabled of button "Export Image" of group "Export Image Pulldown" to true 
set the disabled of button "Screen Selector" of group "Page Selector" to true

Re: Serendipity Editors Fot Images & Icons

Posted: Mon Oct 04, 2021 6:48 pm
by richmond62
The About message in Serendipity Editors requests users contact me privately with questions, bug reports, and comments.
My apologies: knee-jerk there. :?

Re: Serendipity Editors Fot Images & Icons

Posted: Tue Oct 05, 2021 1:45 am
by RCozens
richmond62 wrote:
Sun Oct 03, 2021 6:22 pm
You need to set fields so that they expand and contract to accommodate
the fonts on differing operating systems.
Oh the joys of multiplatform distribution! Thanks for showing me what I can't see without a MacOS box.

Put these lines at the end of the Stack Script's preOpenStack handler:

Code: Select all

   put the top of field "Opening Prompt" into savedTop
   get the formattedHeight of field "Opening Prompt"
   set the height of field "Opening Prompt" to it
   set the top of field "Opening Prompt" to savedTop
   set the top of button "Opening Prompt Display" to (savedTop+it+8)
How does the dataGrid display? Would you please scan an image &/or compare two images. Does the dataGrid format correctly on both platforms, or must I make adjustments there also?

My main concern is the dark background in your screen shot. Here is how the tab control presents itself on Win32:

As you see, the color of the tab is the color of the card background ("244,244,244", the Image Editor's mask color). It appears that I will have to create a color overlay on tab controls on MacOS.

Re: Serendipity Editors Fot Images & Icons

Posted: Tue Oct 05, 2021 8:58 am
by richmond62
Screen Shot 2021-10-05 at 10.54.52 AM.png
-
Screen Shot 2021-10-05 at 10.55.54 AM.png
-
LiveCode 8.1.10, macOS 10.7.5

Re: Serendipity Editors Fot Images & Icons

Posted: Tue Oct 05, 2021 9:19 am
by richmond62
Screen Shot 2021-10-05 at 11.17.12 AM.png
-
Screen Shot 2021-10-05 at 11.17.35 AM.png

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 12:35 am
by RCozens
Serendipity Editors Rev 1 incorporates the bug fixes I posted previously, plus my attempt to deal with the differences between tab controls on Win32 and MacOS. I won't know how well my work-arounds worked until someone with a MacOS box tries it.

If nothing else, this makes it clear to me that anyone planning to deploy LiveCode apps on both platforms really must have access to both platforms or a working relationship with someone who will be their eyes on the platform they lack.

I'm pretty sure the color mask will work; but I don't know if the fields, "Mac Title 3" & "Mac Title 4" are positioned correctly.

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 11:04 am
by richmond62
macOS 10.7.5

This looks a bit odd:
-
Screen Shot 2021-10-07 at 1.03.14 PM.png

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 11:08 am
by richmond62
I just deleted the fields "Mac Title 3" and "Mac Title 4" as they served no obvious purpose:
-
Screen Shot 2021-10-07 at 1.07.40 PM.png
-
I wonder what made you think they were necessary.

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 11:15 am
by richmond62
Someone did not listen to "Uncle Richmond":
-
Screen Shot 2021-10-07 at 1.14.01 PM.png
Screen Shot 2021-10-07 at 1.14.01 PM.png (5.01 KiB) Viewed 7204 times

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 11:21 am
by richmond62
Changed this value from 7 seconds to 15 as I am a slow reader:
-
Screen Shot 2021-10-07 at 1.20.47 PM.png

Re: Serendipity Editors Fot Images & Icons

Posted: Thu Oct 07, 2021 11:23 am
by richmond62
Talk about "relaxing" during one's lunch break:

Re: Serendipity Editors Fot Images & Icons

Posted: Fri Oct 08, 2021 6:11 pm
by RCozens
richmond62 wrote:
Thu Oct 07, 2021 11:08 am
I just deleted the fields "Mac Title 3" and "Mac Title 4" as they served no obvious purpose:
-
Screen Shot 2021-10-07 at 1.07.40 PM.png
-
I wonder what made you think they were necessary.
Hi Richmond,

Thanks for being my eyes on MacOS.
This was an error on my part. I saw the current tab name missing in the image you posted on Oct. 3, and I didn't notice it was corrected in your Oct. 5 images until after I posted Rev 1. Did you make a change or did I fix that in between? I will look into it today.
You were right to delete Mac Titles 3 & 4.

Re: Serendipity Editors Fot Images & Icons

Posted: Fri Oct 08, 2021 6:24 pm
by RCozens
richmond62 wrote:
Tue Oct 05, 2021 8:58 am
Screen Shot 2021-10-05 at 10.54.52 AM.png
-
Screen Shot 2021-10-05 at 10.55.54 AM.png
-
LiveCode 8.1.10, macOS 10.7.5
I hate to tell you this, but replacing my code with your formattedWidth statement does not render correctly on Windows. If you move the button in the Opening Prompt group so it is further down from the prompt field, it may fail on MacOS also. The border you see when the opening prompt is displayed is the border of the group, not the field. Thus my fix addresses the issue of different font sizes by setting the position of the the Opening Prompt Display button a fixed number of bytes below the formattedHeight of the field.

Cheers1