OXT In STEM Education Curriculum

For discussion of xTalk topics related to education.
Post Reply
TerryL
Posts: 92
Joined: Sat Oct 16, 2021 5:05 pm
Contact:

OXT In STEM Education Curriculum

Post by TerryL »

To Paul: I am unable to upload a zipped folder of files, so I emailed it to you. Maybe you could post it here for others. Thanks for all your work on this open source project. We all appreciate the time and effort. edit: finally forum accepted zip folder. Terry

To All: Please look over the files for problems, fixes, especially the demo Print Break stack. Comments welcome.
----

OpenXTalk could reach a wider audience by focusing on teachers and school district administrators under pressure to provide computer science and coding curriculum. My state requirements specify c, c++, visualBasic, python, or "other programming languages". The three local high schools all use MIT's Scratch. Scratch has taken the space that OXT is better suited for, at least for grades 5-12. To that end, I wrote a lesson plan template stack for teachers and 22 STEM (Science Tech Engineering Math) lesson plans featuring OXT to go with it (in attachment). It all lies hidden unless administrators know about OpenXTalk.

How to make OpenXTalk visible? Some type of official direct contact to states and provinces in a coordinated approach? Contact school districts directly? I suspect Scratch made it because administrators were relieved they could satisfy their requirements and keep teachers happy with an easy way out. Teachers didn't need additional training and Scratch provided compliant lesson plans. I found there's quite a racket selling lesson plans for $3-$9 on the internet. I understand now, as it takes about 1.5 hrs to write a good STEM plan, so busy teachers pay out-of-pocket.

LC tried different models for education but didn't get much further than a nationalistic effort in Scotland. Did they try for other English-speaking countries or translate the Dictionary for Spanish? What can OXT do where LC floundered?

An attractive website emphasizing the program's direction and intended audience is critical, with a direct appeal to educators. Attached is a demo site based on LibreOffice's. Too flashy? Too many menuItems?

Raspberry Pi compatibility might be a plus. [-hh] Herman Hoch could provide valuable assistance with RPi and widget development, along with Bernd Niggeman who is also skilled with widgets and may be able to contact Herman for consult. While writing lesson plans I really could have used a Pie Graph and Bar Graph widget to complement the very nice Line Graph widget for students to use in data analysis and reports. I did find a free Pie Chart widget that could be included with standard widgets. Maybe change the name to "Pie Graph" with color options and default colors like Line Graph for continuity? Funny LC made both but names one "Graph" and the other "Chart". Widget "Pie Chart" download: h& ttps://livecode &dot& com/extensions/pie-chart/1-0-0/
----

A Few More IDE And Dictionary Suggestions
Thanks Paul for considering these. Terry

1) Dictionary / printMargins. Currently implies only for printing cards. The printMargins property works with printing cards, fields, and text. Print margin changes remain in effect after the print handler ends. It reverts to default 1 inch ("72,72,72,72") after OXT quits. Set the printMargins to "36,36,36,36" --.5"=36px, 1"=72px, L,T,R,B. Verify with answer page setup or in msg box: put the printMargins.

2) Dictionary / printerSettings. printerSettings could have a realistic example how to extract the returned text, change an item, and set. My impression is that printerSettings is not to be used for changing individual items, but to be used only to save "current settings" and reinstate after changes, not alter the binary. No idea how to extract individual items.

3) Geometry Manager. Wild unexpected resizing. LC bug (23122). This longstanding problem has been solved by Brian Milby, but the fix has never been applied by LC. The workaround is: after adjusting the GM for all controls/groups, adding new controls/groups, and changing layout, in msg box: revCacheGeometry true. Perhaps Brian could assist if you contacted him (through LC forum private message). If successful, you might consider offering the solution to LC Ltd as a gesture of goodwill.

4) Yellow Hilite. Add: Text > Hilite menuItem after 3D Box menuItem.
on mouseUp --hilite/dehilite selection
local tHilite
put selectedChunk(selectedField()) into tHilite --char x to y of fld z
if word 4 of tHilite = "0" then exit to top --no selection
if the backColor of tHilite <> empty then set the backColor of tHilite to empty --dehilite
else set the backColor of tHilite to "255,255,170" --light yellow hilite
end mouseUp

5) RevPrintField Print Break and RevPrintText Print Break. Print cards recognizes a print break (forced new page), but not revPrintField or revPrintText. I've rewritten their code to accept a formfeed character to give the revPrint commands a print break (forced new page) too. I filed an enhancement request with LC a year ago, but they've not done anything with it. [1/11/2021, LC bug (23060), add revPrintText/revPrintField forced page breaks with <%formfeed%> keyword, revPrintField header/footer, yellow hilite for text in menu.] I included a stack demo to test printing to pdf (in folder "Submissions" in the Education section). Dictionary would need updating for revPrintField and revPrintText.

6) Dictionary / RevPrintField.
Syntax: revPrintField fieldDescriptor[,headerText[,footerText]]
Comments: If the field, headerText, or footerText contains any expressions of the form <%expression%>, the expression is evaluated and replaced with value(expression) before the field is printed. Valid expressions would include <%the long date%>, <%the short date%>, <%the short time%>, <%the printPageNumber%>, <%formfeed%>.
For example, if the field contains the text: Today's date is <%the long date%>, the printed text will be: Today's date is Friday, February 15, 2022.
The special value <%formfeed%> in the field is replaced with an invisible nonprinted character that forces a new page print break where inserted. Insert formfeed on a separate line. There are unsatisfactory results with mixed textSizes.
The special values <%pageNumber%> and <%numPages%> are only supported in a header or footer.

The headerText and footerText can contain up to two tab characters:
* Everything up to the first tab character is left-aligned.
* Everything between the first and second tab character is centered.
* Everything after the second tab character is right-aligned.
If the headerText or footerText contain more than two tab characters, everything after the third tab is ignored.

7) Dictionary / RevPrintText.
Comments: if the textToPrint, headerText, or footerText contains any expressions of the form <%expression%>, the expression is evaluated and replaced with value(expression) before the text is printed. Valid expressions would include <%the long date%>, <%the short date%>, <%the short time%>, <%the printPageNumber%>, <%formfeed%>.
For example, if the text contains: Today's date is <%the long date%>, the printed text will be: Today's date is Friday, February 15, 2022.
The special value <%formfeed%> in the text is replaced with an invisible nonprinted character that forces a new page print break where inserted. Insert formfeed on a separate line. There are unsatisfactory results with mixed textSizes.
The special values <%pageNumber%> and <%numPages%> are only supported in a header or footer.

The headerText and footerText can contain up to two tab characters:
* Everything up to the first tab character is left-aligned.
* Everything between the first and second tab character is centered.
* Everything after the second tab character is right-aligned.
If the headerText or footerText contain more than two tab characters, everything after the third tab is ignored.

8) Dictionary / scaleFactor. Could add: The scaleFactor setting is not persistent, stack and standalone revert to original size. To make persistent, in stack script (or card 1 script of mainstack if there are substacks):
on preOpenStack
set the scaleFactor of this stack to ".7" --scale smaller
end preOpenStack

9) Dictionary in windows 10 with backdrop opens behind the backdrop. (LC bug 17388, 4/2016, v8x+) The workaround is to click anywhere on the backdrop to bring Dictionary to front. LC has ignored this since v8x, so maybe a hard fix. Confusing for new users.
Attachments
Submission TerryL.zip
(909.16 KiB) Downloaded 692 times
LessonPlan.jpg
LessonPlan.jpg (129.34 KiB) Viewed 17580 times
mdm
Posts: 22
Joined: Thu Sep 16, 2021 2:15 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by mdm »

Hi Terry

[quote]Herman Hoch could provide valuable assistance with RPi and widget development[/quote]

Hermann died in April 2020, sadly.
Even before that he had given up all his efforts in LC publicly.
So not much help from that side.
User avatar
richmond62
Posts: 3297
Joined: Sun Sep 12, 2021 11:03 am
Location: Bulgaria
Contact:

Re: OXT In STEM Education Curriculum

Post by richmond62 »

Writing as a teacher of both EFL and programming of 35 years experience
the first thing I would do is forget about precise lesson plans.

I have taught Intro to LiveCode for 9 years, every summer, to 9-15 year olds:
lesson plans have NEVER worked: vague target notes scribbled down on scrap
paper have proven useful up to a point: children differ in all sorts of ways.

I tend to teach how to use the programming environment first, and turn
to grand plans ("the environment") much, much later: as doing it the other way round
seems to betray a lack of understanding as to how children learn,
https://richmondmathewson.owlstown.net/
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

richmond62 wrote: Wed Jan 19, 2022 3:09 pm Writing as a teacher of both EFL and programming of 35 years experience
the first thing I would do is forget about precise lesson plans.

I have taught Intro to LiveCode for 9 years, every summer, to 9-15 year olds:
lesson plans have NEVER worked: vague target notes scribbled down on scrap
paper have proven useful up to a point: children differ in all sorts of ways.

I tend to teach how to use the programming environment first, and turn
to grand plans ("the environment") much, much later: as doing it the other way round
seems to betray a lack of understanding as to how children learn,
I'd say that adding tools to help Teachers through the bureaucracy requirements could help attract users in education here in the US. I know I'm appalled by what I've seen from 'STEM' education having three sons go/went though the public school system here in Southern New Jersey.
I actually know quite a few teachers (nieces/several friends), although none are IT, IS programming teachers. Funding, I'm sure is a big the issue. From what I hear, it's a constant battle between teachers/union and the forces of 'conservatives' that want to cut funding and services to keep taxes down. And many teachers are under paid and have to buy supplies themselves, or ask parents to help with supplies. The public school system across every town, every county, in every State in US, varies widely as far as what they can afford to do. It's a huge market but all free stuff like Scratch/Squeak,Python, and Alice have filled that space, even though in my opinion learning *xTalk has a lower learning curve and is far more intuitive, at least to English speaking people, for people with little or no exposure to development environments. It certainly got me hooked for life as a teen (sometime around the late 1980s).

The price point of "free" is really a good 'selling' point, but we can make it even more attractive by including pre-made lesson plans, at least useful for submitting info to the higher-ups at the Board of Education or whatever. And offering a tool to help teachers in general is a great idea. Start with a lesson plan generator that outputs to print or pdf file for emailing, later add things like a Quiz generator, maybe even a Kiosk-mode Test taker client app that connects to a server Test receiver app that runs on the Teacher's computer! And my person interest in music has already gotten some people contacting me about using that for 'music theory' type analysis tools and the like, I plan to bring all of the interactive music features of previous xTalks (HyperCard,SuperCard at least) back, along with music theory related widgets and librarie(s), much of that is already well into development. This could useful for Music Teachers. There's quite a few music theory/education stacks from decades past (that's how I got started with learning piano scales and chords).

I'm all for it! I would help any teacher that wants to try to get this into use in US Public schools in anyway that I can. I've worked in commercial printing for 30 years, and I'm pretty good with graphics and page layout things, like making little trifold brochures, actual books with spines, etc. I honestly think that xTalk belongs in public schools, 100%!
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

TerryL wrote: Tue Jan 18, 2022 8:37 pm To Paul: I am unable to upload a zipped folder of files, so I emailed it to you. Maybe you could post it here for others. Thanks for all your work on this open source project. We all appreciate the time and effort. edit: finally forum accepted zip folder. Terry

To All: Please look over the files for problems, fixes, especially the demo Print Break stack. Comments welcome.
----
Thanks, will do...
OpenXTalk could reach a wider audience by focusing on teachers and school district administrators under pressure to provide computer science and coding curriculum. My state requirements specify c, c++, visualBasic, python, or "other programming languages". The three local high schools all use MIT's Scratch. Scratch has taken the space that OXT is better suited for, at least for grades 5-12. To that end, I wrote a lesson plan template stack for teachers and 22 STEM (Science Tech Engineering Math) lesson plans featuring OXT to go with it (in attachment). It all lies hidden unless administrators know about OpenXTalk.

How to make OpenXTalk visible? Some type of official direct contact to states and provinces in a coordinated approach? Contact school districts directly? I suspect Scratch made it because administrators were relieved they could satisfy their requirements and keep teachers happy with an easy way out. Teachers didn't need additional training and Scratch provided compliant lesson plans. I found there's quite a racket selling lesson plans for $3-$9 on the internet. I understand now, as it takes about 1.5 hrs to write a good STEM plan, so busy teachers pay out-of-pocket.

LC tried different models for education but didn't get much further than a nationalistic effort in Scotland. Did they try for other English-speaking countries or translate the Dictionary for Spanish? What can OXT do where LC floundered?

An attractive website emphasizing the program's direction and intended audience is critical, with a direct appeal to educators. Attached is a demo site based on LibreOffice's. Too flashy? Too many menuItems?
Did LC try different models for education? And where did they try it?
I happened to know one teacher that is a long time HC,MC,RR/LC user has privately told me a different story,
I'll paste that exchange here:
Larry Tessler was one of the venture capitalists who invested in Apple to help get it off the ground and to stay off the ground. At one of the then-Rev user conferences, he made a surprising show and attended BOTH of my unscheduled BOF groups on using Rev in the classroom. His daughter is a public schoolteacher and he spoke on the subject of how Rev could be so very useful in teaching and learning. I definitely informed Richard and Kevin & Co. that he was there making overtures. Sadly, it never went any further than that and the company and its front people are trying to deny he was ever there. If I had shown him the door, I suspect I wouldn't want people to know about it either.

Raspberry Pi compatibility might be a plus. [-hh] Herman Hoch could provide valuable assistance with RPi and widget development, along with Bernd Niggeman who is also skilled with widgets and may be able to contact Herman for consult. While writing lesson plans I really could have used a Pie Graph and Bar Graph widget to complement the very nice Line Graph widget for students to use in data analysis and reports. I did find a free Pie Chart widget that could be included with standard widgets. Maybe change the name to "Pie Graph" with color options and default colors like Line Graph for continuity? Funny LC made both but names one "Graph" and the other "Chart". Widget "Pie Chart" download: h& ttps://livecode &dot& com/extensions/pie-chart/1-0-0/
----
I love the Raspberry Pi and other cheap single-board computers, which are perfect low-cost solutions for classrooms in districts with malnourished coffers, and OXT could be the perfect "PROGRAMMING 101" companion to that!
The RealBASIC XOJO people do RPi (with much more realistic "Hobbyist" licensing than LC too, IMO), OXT could too. I would LOVE for someone to do an updated (9.x) build of the Community binaries for ARM/RPi. I currently no longer have my RPi 3B+ to test on, but I could maybe change that.

I did get a small funding coming in from someone (THANK YOU SO MUCH, whomever you are!), it's enough money already to use for small things, like a RPi to test on. But I'm reluctant to spend it on anything just yet. I want to get a better picture of what it needs to be spent on. For example, it would be good to sign-up for a ($99/year) Apple Dev subscription account, which would allow me to get the OXT macOS binaries Notarized. The is only way to avoid scaring off potential users with scary "Unidentified Developer" warnings! I've self-signed, with declared entitlements (request allow use microphone, for example) the code requirements of the macOS app bundle with a "OpenXTalk.org" digital certificate that I created myself, this eliminates some warnings but not all. The only way to do that is to have them Notarized by Apple, and that requires a paid account. Also, obviously we have to keep a hold of the Openxtalk.org domain name, so that's a small expense there (I really need to talk to Seth about that sometime soon). But I'm definitely interested in supporting RPi (and similar SOC boards).

The most RPi support from the community came from Hermann "HH" Hoch, who as mention, unfortunately died in 2021.
He did some great experiments with the Pi, as well as with JS and Extension Builder, MUCH of which he explicitly released to the public! I definitely think we can include some of his great work in one form or another. I'm particularly interested in using his excellent IconGrid widget as the basis for IDE Palettes, it could be a good way of remembering his contributions to the community! Rest In Peace and Thank You HH!
A Few More IDE And Dictionary Suggestions
Thanks Paul for considering these. Terry

1) Dictionary / printMargins. Currently implies only for printing cards. The printMargins property works with printing cards, fields, and text. Print margin changes remain in effect after the print handler ends. It reverts to default 1 inch ("72,72,72,72") after OXT quits. Set the printMargins to "36,36,36,36" --.5"=36px, 1"=72px, L,T,R,B. Verify with answer page setup or in msg box: put the printMargins.
One inch print margins on all 4 sides, as a default? That seems a bit wasteful.
2) Dictionary / printerSettings. printerSettings could have a realistic example how to extract the returned text, change an item, and set. My impression is that printerSettings is not to be used for changing individual items, but to be used only to save "current settings" and reinstate after changes, not alter the binary. No idea how to extract individual items.
Even though I'm involved in printing at the day job, I've never really used LCC/OXT's report printing capabilities. I probably last used HyperCard's report printing (which I assume was the inspiration for revPrint) sometime around the mid-1990s. But you've peaked my interest. It seems like we already have everything that is needed to produce a 'OXT User Manual" PDF directly from within the IDE!
3) Geometry Manager. Wild unexpected resizing. LC bug (23122). This longstanding problem has been solved by Brian Milby, but the fix has never been applied by LC. The workaround is: after adjusting the GM for all controls/groups, adding new controls/groups, and changing layout, in msg box: revCacheGeometry true. Perhaps Brian could assist if you contacted him (through LC forum private message). If successful, you might consider offering the solution to LC Ltd as a gesture of goodwill.
Geometry Manager is another feature that I've never really looked into too much, but really should. Proportional layouts would be useful for building in the IDE, though it's not really that difficult to roll your own from scratch. I will deffinitey look into this.
4) Yellow Hilite. Add: Text > Hilite menuItem after 3D Box menuItem.
on mouseUp --hilite/dehilite selection
local tHilite
put selectedChunk(selectedField()) into tHilite --char x to y of fld z
if word 4 of tHilite = "0" then exit to top --no selection
if the backColor of tHilite <> empty then set the backColor of tHilite to empty --dehilite
else set the backColor of tHilite to "255,255,170" --light yellow hilite
end mouseUp


Hilite menuItem yellow after 3D Box menuItem? I'm not sure what you mean, I haven't looked at the files yet.
5) RevPrintField Print Break and RevPrintText Print Break. Print cards recognizes a print break (forced new page), but not revPrintField or revPrintText. I've rewritten their code to accept a formfeed character to give the revPrint commands a print break (forced new page) too. I filed an enhancement request with LC a year ago, but they've not done anything with it. [1/11/2021, LC bug (23060), add revPrintText/revPrintField forced page breaks with <%formfeed%> keyword, revPrintField header/footer, yellow hilite for text in menu.] I included a stack demo to test printing to pdf (in folder "Submissions" in the Education section). Dictionary would need updating for revPrintField and revPrintText.

6) Dictionary / RevPrintField.
Syntax: revPrintField fieldDescriptor[,headerText[,footerText]]
Comments: If the field, headerText, or footerText contains any expressions of the form <%expression%>, the expression is evaluated and replaced with value(expression) before the field is printed. Valid expressions would include <%the long date%>, <%the short date%>, <%the short time%>, <%the printPageNumber%>, <%formfeed%>.
For example, if the field contains the text: Today's date is <%the long date%>, the printed text will be: Today's date is Friday, February 15, 2022.
The special value <%formfeed%> in the field is replaced with an invisible nonprinted character that forces a new page print break where inserted. Insert formfeed on a separate line. There are unsatisfactory results with mixed textSizes.
The special values <%pageNumber%> and <%numPages%> are only supported in a header or footer.

The headerText and footerText can contain up to two tab characters:
* Everything up to the first tab character is left-aligned.
* Everything between the first and second tab character is centered.
* Everything after the second tab character is right-aligned.
If the headerText or footerText contain more than two tab characters, everything after the third tab is ignored.

7) Dictionary / RevPrintText.
Comments: if the textToPrint, headerText, or footerText contains any expressions of the form <%expression%>, the expression is evaluated and replaced with value(expression) before the text is printed. Valid expressions would include <%the long date%>, <%the short date%>, <%the short time%>, <%the printPageNumber%>, <%formfeed%>.
For example, if the text contains: Today's date is <%the long date%>, the printed text will be: Today's date is Friday, February 15, 2022.
The special value <%formfeed%> in the text is replaced with an invisible nonprinted character that forces a new page print break where inserted. Insert formfeed on a separate line. There are unsatisfactory results with mixed textSizes.
The special values <%pageNumber%> and <%numPages%> are only supported in a header or footer.

The headerText and footerText can contain up to two tab characters:
* Everything up to the first tab character is left-aligned.
* Everything between the first and second tab character is centered.
* Everything after the second tab character is right-aligned.
If the headerText or footerText contain more than two tab characters, everything after the third tab is ignored.
Seems revPrinting needs some love / attention.

There's also several PDF generation libraries that could incorporated in order to build a new Print/PDF generating API in OXT. One of them is the PDFKit.JS (not to be confused with Apple's PDFKit, which I've already made a wrapper library for), which is a JavaScript library and so it can be used via the Browser Widget.
8) Dictionary / scaleFactor. Could add: The scaleFactor setting is not persistent, stack and standalone revert to original size. To make persistent, in stack script (or card 1 script of mainstack if there are substacks):
on preOpenStack
set the scaleFactor of this stack to ".7" --scale smaller
end preOpenStack
scaleFactor setting is not persistent??? It is for me! As long as I save the Stack after setting it. Maybe this is a platform specific bug?
9) Dictionary in windows 10 with backdrop opens behind the backdrop. (LC bug 17388, 4/2016, v8x+) The workaround is to click anywhere on the backdrop to bring Dictionary to front. LC has ignored this since v8x, so maybe a hard fix. Confusing for new users.
I doubt that it's all that hard of a fix, a "Window" object is a pretty basic element of any GUI application. I think it's more likely that this is a very low priority feature and so it it's been neglected. There's other nice ideas that made it into the IDE at some point that have largely been neglected since. The Guided Tour/revTutorial API comes to mind.

The fix should just be reordering the window that is the backdrop window to the back of the on screen windows, which I don't know if you can do from regular Script, since the Backdrop window is not a Stack, but it could be done fairly easily with Extension Builder. I'm planning on doing a deep dive into the Windows/Linux side of things soon, I want to try to wrap some of GTK and WinRT++ and similar.

In fact I've been thinking that it could be really great to include big chunk of GNUStep and dependencies (or ports like WinObjC or Darwinian) with OXT on all platforms. This would give OXT a well formed Application Framework that is consistent across all 3 IDE Platforms while providing a bunch of features to expose to the Engine, some extremely useful features (like the NSURL, NSNotificationManager, CoreImage, all of CoreFoundation, basically everything in that was available to OpenStep Developers plus some FOSS implementations of Cocoa and newer things), GNUStep has seen some renewed interest lately, it's 30+ years old and still around so that's a good indicator of it's longevity/wherewithal! Let's try to find out what could've happened if Bill Atkinson and HC had jumped ship to Steve Job's NeXT (where the early web was developed) back around 1989/90, lol! I certainly want to investigate the idea, perhaps it could help in moving OXT to an alternative engine, one that uses GNUStep in conjunction with ReactNative's ObjC lib or similar, at some point...who knows. That could also mean we could embed StepTalk or SmallTalk or offer other possibilities I haven't imagined. At the least, I believe this would give us access to cross platform speech synthesis API as well (FOSS answer to NSSpeech) and a 'PDFKit' too!
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

Heavily MultiTasking Today! I just got around to installing the new version of 'helloSystem' the heavily macOS 'inspired' FreeBSD distro which is running quite well on my old (4th gen Core i5) laptop, enough that I'll install it on the internal drive with the Linux subsystem which should allow OXT to run.

I also looked at Page Break and now understand the 'Add Yellow Hilite' suggestion.
My comments:
I'm using macOS native darkmode, and so when I open this stack, due to the property inheritance any field text (and interestingly this seems to effect certain single-color graphical objects too) with it's foreColor set to 'empty' will automatically be rendered as either black, white, OR it's set to the foreColor of the next object (group-background/card/stack) up in it's inheritance chain if the property is set in a parent object. Text fields with backColor set to 'empty' are automatically filled dark (black actually), white, or it inherits it's color properties from a parent object as well. If that property is empty all the way though the chain, then it's inherited from the app or operating system. The result onscreen typically (at least on macOS) should be black text on a white background OR white text on a black background, dependent on the users light/dark system setting...UNLESS, we're talking about printing on paper, then the engine assumes that the background is going to be white (and you could be trying to print opaque white inks on a dark medium, just sayin'). So what is happening is the fld text is printed as white text on white paper and so is invisible in a print (PDF) document. The text data is still in the PDF, it's selectable, but it's colored white!
Screen Shot 2022-01-20 at 10.53.37 AM.png
Screen Shot 2022-01-20 at 10.53.37 AM.png (1.69 MiB) Viewed 17563 times
Similarly the yellow hilite text handler needed tweaking to be readable (was white textColor on yellow backColor)

Code: Select all

on mouseUp  --hilite/dehilite selection
   local tHilite
   put selectedChunk(selectedField()) into tHilite  --char x to y of fld z
   if word 4 of tHilite = "0" then exit to top  --no selection
   if the backColor of tHilite <> empty then 
      set the backColor of tHilite to empty  --dehilite
      set the foreColor of tHilite to empty  -- IF EMPTY foreColor is INHERITED from the next object up in the object hierarchy
   else 
      set the backColor of tHilite to "255,255,170"  --lite yellow hilite
      set the foreColor of tHilite to "0,0,0"  -- explicitly set to black otherwise it may be white if the system is in 'darkmode'.
   end if
end mouseUp
I actually planned to go much further than a hi-lighter as far as adding text editing capabilities. For one thing I'm considering adding Hunspell libraries, based on what Trevor DeVore released to the community a couple of years ago, but across all 3 IDE platforms (and deploys across all except IOS which can use NSSpell instead). This will have several uses for the IDE beyond spell check, I've made a hunspell 'dictionary' file with all (or most of) the keywords in the Scripting syntax, which I was thinking could be used to implement an auto-complete text in the script editor. Additionally, I want to add an IDE text editor palette that can set text/fld properties on any objects, not just text fields, and it will have options for different object types to apply to, or not, those target properties in parent objects (groups/card/stacks/template objects) up through the inheritance chain. I've always thought that the IDE's facilities have been rather weak as far as tools for graphical layout/design tools. It's certainly an area I want to try to improve on along the way.
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

I made an OpenXTalk YouTube Channel.
There is only one video clip on there so far.
I think it could be great if we had walk-through videos of this lessons plan.
Then we can link to the videos in the lessons (I mean xTalk IS a HyperMedia platform, right?).
If anyone wants to contribute videos (once we have a release that you can use in the videos) let me know and I'll add a link.
It could have playlist categories, lessons, new features, bug report bug-demonstrations, etc.
https://www.youtube.com/channel/UCdGi5N ... xfQvKX0NPA
micmac
Posts: 130
Joined: Mon Sep 13, 2021 9:46 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by micmac »

Hi Paul

Is the Page Break a Stack

if so can you point to it?

Thanks
Mic
User avatar
tperry2x
Posts: 2006
Joined: Tue Dec 21, 2021 9:10 pm
Location: Somewhere in deepest darkest Norfolk, England
Contact:

Re: OXT In STEM Education Curriculum

Post by tperry2x »

That looks very interesting. I'm not set up with xcode right now. I was wondering if we could have a 'builds' category on the forum where we can download and try out a compiled binary - even if it's an 'extremely alpha' release.
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

tperry2x wrote: Fri Jan 21, 2022 5:32 pm That looks very interesting. I'm not set up with xcode right now. I was wondering if we could have a 'builds' category on the forum where we can download and try out a compiled binary - even if it's an 'extremely alpha' release.
Yes, that is still currently my main goal. There have been some unforeseen distractions eminating from my day-to-day life recently, but I do still want to get something out to you guys, the handful of people here that are actually interested in trying this, soon. Get some different eyeballs on it, I'm sure there's some typos to catch at least! I think, I've worked out the macOS side of packaging things for release well enough for beta testing, and now I plan to turn my attention to creating an AppImage as the format for releasing on Linux (because it's built for self-contained portability), the closest thing on Linux to a macOS .app bundle). Windows is actually the platform that I have the least experience with as a user (I've avoided MS products like they're COVID19!), I'm not sure entirely sure what is the best way to package an IDE distro for that platform? I could just compress the IDE directory as a zip and upload it somewhere (likely will upload to a GoogleDrive or MEGA.nz cloud storage) I guess... but you could basically get such a OXT .zip file right now from the "Don't Panic Edition" IDE repo on GitHub, although you'd have to take some additional small steps after downloading and decompressing it in order for everything to work as intended (I had to compress certain large libraries used by the CEF Browser widget engine) and additionally I my have changes that I haven't yet pushed to that repo, so just beware. I've been making small changes but I've been making them often.
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

micmac wrote: Fri Jan 21, 2022 4:03 pm Hi Paul

Is the Page Break a Stack

if so can you point to it?

Thanks
Mic
Yes, like most things that aren't the interpreter engine(s) this is a part of the IDE.
It's mainly from a script-only stack called "revprintlibrary.livecodescript"
There is also several related, binary (GUI) stacks in the palettes folder:
revprinterchooser.rev
revprintdialog.rev
revpagesetupdialog.rev
revpagesetup.rev

There's also the iOS 'AirPrint' compatible external called rreHardcopyPrintPDF and a few other PDF related things released by the community, but that's not what we're talking about here.
Screen Shot 2022-01-21 at 7.05.16 PM.png
Screen Shot 2022-01-21 at 7.05.16 PM.png (555.78 KiB) Viewed 17545 times
micmac
Posts: 130
Joined: Mon Sep 13, 2021 9:46 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by micmac »

OpenXTalkPaul wrote: Sat Jan 22, 2022 12:00 am I've been making small changes but I've been making them often.
Paul, when I look at GitHub the changes are 3-4 month old. (maybe I do not understand the process)

Was the first goal not to just remove the LiveCode name?

Mic
TerryL
Posts: 92
Joined: Sat Oct 16, 2021 5:05 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by TerryL »

To Paul: I retested scaleFactor. It is persistent after quitting as a stack but not as a standalone. I should have been more specific. And this is noted in the 9.6.3 dictionary, which I did not check at the time. I was using another version's dictionary. Sorry for the confusion. Please strike the scaleFactor suggestion.

To everyone: If you mean my Page Break demo stack, it is in the zipped folder attachment "Submissions". Please try it out. Terry
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

micmac wrote: Sat Jan 22, 2022 10:09 am
OpenXTalkPaul wrote: Sat Jan 22, 2022 12:00 am I've been making small changes but I've been making them often.
Paul, when I look at GitHub the changes are 3-4 month old. (maybe I do not understand the process)

Was the first goal not to just remove the LiveCode name?

Mic
Which repo(s) are you looking at? Because I've been pushing changes almost every day.

The IDE Repo: This is where the bulk of the work I've been doing lives. NOTE: this currently has a slightly different folder structure from the LCC engine repo.
https://github.com/OpenXTalk-org/OpenXt ... nicEdition
The Engine(s) Repo, which is currently mostly the same as the LCC Engine repo, with the exception of the Docs folders (also I may have pushed a few building process specific files that Xcode creates), is here:
https://github.com/OpenXTalk-org/OpenXT ... munity-DPE
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

TerryL wrote: Sat Jan 22, 2022 6:24 pm To Paul: I retested scaleFactor. It is persistent after quitting as a stack but not as a standalone. I should have been more specific. And this is noted in the 9.6.3 dictionary, which I did not check at the time. I was using another version's dictionary. Sorry for the confusion. Please strike the scaleFactor suggestion.

To everyone: If you mean my Page Break demo stack, it is in the zipped folder attachment "Submissions". Please try it out. Terry
Hmm, my guess is that (newer) stack property is being lost in the process whereby a mainStack is merged with the standalone app engine binary when it's built. I did a quick test and this code does work in a standalone on my mac (11.x BigSur):

Code: Select all

--on preOpenStack 
--   set the scaleFactor of me to 0.5 -- THIS DOES NOT WORK  --
--  I'm guessing that because this is 'preOpen...' that means the window hasn't yet been created by the engine.
--end preOpenStack

on openStack 
   set the scaleFactor of this stack to 0.5 -- THIS DOES WORK in a standalone <--
end openStack
User avatar
richmond62
Posts: 3297
Joined: Sun Sep 12, 2021 11:03 am
Location: Bulgaria
Contact:

Re: OXT In STEM Education Curriculum

Post by richmond62 »

This coming July, all things being equal, I have a good mind to video my LiveCode lessons
so people can see at least one way of teaching the thing without the benefit of either
lesson plans or orders handed down "from on high."
https://richmondmathewson.owlstown.net/
TerryL
Posts: 92
Joined: Sat Oct 16, 2021 5:05 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by TerryL »

ScaleFactor Persistence And Standalone
Nice catch Paul. I guess scaleFactor needs Dictionary update after all. On Win10 I verify scaleFactor is persistent for main and substacks, but not for standalones, and that setting scaleFactor for standalone in a preOpenStack doesn't work (9.6.3 dictionary says it does). An openStack does work, but on startup works too, and is designed for standalone while ignored by stack and substack.
I tried to update the Submissions folder but failed repeatedly. Edit: was able to upload as an edit.

Code: Select all

--in mainstack stack script:
on preOpenStack  --scaleFactor persistent for main and substacks.
   set the topLeft of stack "ScaledMain" to "225,225"
   open stack "ScaledSub"
   set the topLeft of stack "ScaledSub" to the topRight of stack "ScaledMain"
end preOpenStack

on startup  --standalone only, ignored by stack. ScaleFactor not persistent, must be explicitly set.
   set the scaleFactor of stack "ScaledMain" to ".5"
   set the topLeft of stack "ScaledMain" to "225,225"
   open stack "ScaledSub"
   set the scaleFactor of stack "ScaledSub" to ".5"
   set the topLeft of stack "ScaledSub" to the topRight of stack "ScaledMain"
end startup
Attachments
Submission TerryL.zip
(909.35 KiB) Downloaded 677 times
User avatar
OpenXTalkPaul
Posts: 1877
Joined: Sat Sep 11, 2021 4:19 pm
Contact:

Re: OXT In STEM Education Curriculum

Post by OpenXTalkPaul »

TerryL wrote: Fri Jan 28, 2022 9:39 pm I tried to update the Submissions folder but failed repeatedly. Edit: was able to upload as an edit.
I REALLY need to fix that. It's a problem that was introduced while trying to reduce our spam problem.
There's a time limit that makes posts time-out rather quickly, but upon repeating the post action it should go through.
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests