Re-draw problem in the Script Editor

Using SuperCard and the Runtime Editor... working with windows, backgrounds, cards and menus.

Re-draw problem in the Script Editor

Postby DaveFrancis » Fri Apr 28, 2017 5:36 pm

I deleted a small section of a field's script in the script editor, using control-x. Only the first line disappeared and the rest remained highlighted. The insertion cursor was still winking on the empty line, but I couldn't move it by clicking elsewhere. I closed the script with the OK button, then re-opened it, and the deleted portion had gone.

I've tried it again and the same happens each time. Also, if I paste stuff into a script, it's there but it doesn't show until something else causes the window to re-draw.

Dave.
DaveFrancis
 
Posts: 294
Joined: Fri Mar 06, 2009 5:12 pm

Re: Re-draw problem in the Script Editor

Postby DaveFrancis » Sat Apr 29, 2017 2:33 pm

Of course the window can be cleaned up by scrolling the changed section of script out of sight momentarily. So it's not much of an inconvenience really.

Dave.
DaveFrancis
 
Posts: 294
Joined: Fri Mar 06, 2009 5:12 pm

Re: Re-draw problem in the Script Editor

Postby Scott » Mon May 01, 2017 1:40 am

I can't reproduce this here in b27...

SuperCard, SuperEdit, or both?

What are the settings in the Editor (syntax coloring, line numbers, font and tab size settings)?

How many lines in this script?

Is it just this script or are they all behaving this way?

Version of MacOS?
User avatar
Scott
Site Admin
 
Posts: 1203
Joined: Sat Jul 05, 2008 1:37 pm
Location: Northern Sierra Nevada

Re: Re-draw problem in the Script Editor

Postby JoeKoomen2011 » Mon May 01, 2017 6:27 am

I have seen script redraw anomalies myself. If you change the script font sizes in SuperEdit, the entire script gets messed up and you have to close the window and reopen it to be able to continue editing.

Occasionally I have noticed the formatting (especially the indenting) getting wacky at the bottom of the screen/script window. As Dave says, scrolling or closing the window corrects this.

Joe
Joe Koomen
>> Random! ...Damn near killed 'em! <<
User avatar
JoeKoomen2011
 
Posts: 447
Joined: Thu Mar 12, 2009 1:38 pm

Re: Re-draw problem in the Script Editor

Postby sctell » Mon May 01, 2017 7:38 am

DaveFrancis wrote:Also, if I paste stuff into a script, it's there but it doesn't show until something else causes the window to re-draw.
Dave.


I can confirm having observed this.

I usually scroll the window then scroll it back and the script displays correctly.


All the best

Terry
sctell
 
Posts: 1111
Joined: Sun Jul 06, 2008 10:41 am

Re: Re-draw problem in the Script Editor

Postby codegreen » Mon May 01, 2017 8:03 am

I've spent over an hour trying to reproduce these problems, but like Scott so far I haven't seen anything unusual going on.

Can someone offer a more precise recipe?

Thanks,
-Mark
codegreen
 
Posts: 1477
Joined: Mon Jul 14, 2008 11:03 pm

Re: Re-draw problem in the Script Editor

Postby sctell » Mon May 01, 2017 10:07 am

codegreen wrote:Can someone offer a more precise recipe?


I just ......

1. Opened a project

2. Opened the Project Script

3. Copied the OpenProject handler

4. Paste the copied text underneath the existing handler.

5. The only additional text I could see was "on OpenProject".

6. Scrolled down the Project Script until the copied handler was not visible.

7. Scrolled back and there it was, the pasted handler was now visible.


All the best

Terry

PS I'll do a movie of the screen if required?
sctell
 
Posts: 1111
Joined: Sun Jul 06, 2008 10:41 am

Re: Re-draw problem in the Script Editor

Postby Scott » Tue May 02, 2017 5:01 am

Ok I am seeing something similar in SuperCard, not SuperEdit... right?

Thanks.
User avatar
Scott
Site Admin
 
Posts: 1203
Joined: Sat Jul 05, 2008 1:37 pm
Location: Northern Sierra Nevada

Re: Re-draw problem in the Script Editor

Postby sctell » Tue May 02, 2017 5:38 am

Scott wrote:Ok I am seeing something similar in SuperCard, not SuperEdit... right?


Hi,

My comments relate to SuperCard.

All the best

Terry
sctell
 
Posts: 1111
Joined: Sun Jul 06, 2008 10:41 am

Re: Re-draw problem in the Script Editor

Postby DaveFrancis » Wed May 03, 2017 10:36 pm

Yes I was in SuperCard too. I'm using some syntax colours (not default), the font is Arial Narrow 18 which is global, and the tab is 2.

Strangely I can't seem to reproduce the Cmd-x thing just now, but pasting stuff in is now showing various anomalies.The problem only seems to happen when pasting at the bottom of the window. Mostly it shows me the pasted text without it's first line, with the cursor flashing on the empty line. But I've just tried squeezing the pasted text in front of other stuff (again near the bottom of the window) and it didn't displace anything, didn't show at all.

Scrolling always cleans it up though.

Oddly enough (and this is probably nothing to do with the subject under discussion) I've just noticed that the font for the window I've been testing, is set under 'This Script' to American TypeWriter, and refuses to be changed to Arial Narrow. Even so, the text displays in the Arial Narrow font.

Dave.
DaveFrancis
 
Posts: 294
Joined: Fri Mar 06, 2009 5:12 pm

Re: Re-draw problem in the Script Editor

Postby JoeKoomen2011 » Mon May 15, 2017 7:07 am

I am seeing this problem in SuperEdit as well. It's hard to reproduce. Below you can see the "on buildExclusiveSortMenus" is indented when it shouldn't be.

offset.png
offset.png (50.01 KiB) Viewed 279 times


To produce this, I was editing a long script (projectScript naturally) and when I scrolled down I noticed the bizarre indenting. As soon as I resized the script window, everything went back to normal.

It doesn't happen often and is hard to reproduce, but it is happening.

Joe
Joe Koomen
>> Random! ...Damn near killed 'em! <<
User avatar
JoeKoomen2011
 
Posts: 447
Joined: Thu Mar 12, 2009 1:38 pm

Re: Re-draw problem in the Script Editor

Postby JoeKoomen2011 » Fri Jun 30, 2017 11:09 am

While it doesn't happen often, it does do weird redraws with the syntax colouring. The screen captures below were taken this morning. I borrowed and old script - pasting it into the script window of a new button. I typed in a new line and hit return. As you can see, the first letter of each line is at the and of the previous line.

image1.png
On return
image1.png (51.31 KiB) Viewed 124 times


After I resized the window a bit, the scripts were readable, but the syntax colouring on the first letter was wrong.

image1.png
On return
image1.png (51.31 KiB) Viewed 124 times


After I typed a few more lines in the window, things cleared up.
Attachments
image2.png
On resize
image2.png (47.87 KiB) Viewed 124 times
Joe Koomen
>> Random! ...Damn near killed 'em! <<
User avatar
JoeKoomen2011
 
Posts: 447
Joined: Thu Mar 12, 2009 1:38 pm


Return to SuperCard Basics

Who is online

Users browsing this forum: No registered users and 1 guest

cron