Search found 3442 matches

by bn
Mon Apr 12, 2021 1:32 pm
Forum: Multimedia
Topic: Append an image to another image
Replies: 27
Views: 6216

Re: Append an image to another image

Hi Seal, Here is a stack that creates a group of 3 thumbnails from 1 thumbnail and then imports a snapshot from that group. The point is that I can not notice a degradation of image quality in the snapshot. createThumbnails.livecode.zip @Thierry I like the snippet of code for manipulating imageData....
by bn
Mon Apr 12, 2021 7:47 am
Forum: Multimedia
Topic: Append an image to another image
Replies: 27
Views: 6216

Re: Append an image to another image

Could you upload an image you are trying to take a snapshot of? Or an image similar in quality and size?

Kind regards
Bernd
by bn
Sun Apr 11, 2021 11:39 pm
Forum: Multimedia
Topic: Append an image to another image
Replies: 27
Views: 6216

Re: Append an image to another image

Hi Seal, I think the easiest way would be to position the images next to each other manually then group them (set the margins of the group to 0) and import or export a snapshot of the group. That would result in a single image. You could also place the individual images in the group and then scroll ...
by bn
Mon Mar 22, 2021 4:56 pm
Forum: Off-Topic
Topic: Navigation arrows on keyboard not working in script editor
Replies: 13
Views: 917

Re: Navigation arrows on keyboard not working in script editor

Thanks Bernard: Interestingly, I followed your instructions deleting my preferences and when I relaunched LC it worked for a moment in the message box but by the time I tried to edit the stack the behaviour had returned to the usual of ignoring my navigation keys. But there was an instant when it w...
by bn
Mon Mar 22, 2021 11:23 am
Forum: Off-Topic
Topic: Navigation arrows on keyboard not working in script editor
Replies: 13
Views: 917

Re: Navigation arrows on keyboard not working in script editor

That sounds odd. You could try to remove the LC preferences from the preferences folder of your system while LC is closed. Then restart LC and see if it works now. LC rebuilts a new preference folder if there is none. On a Mac LC preferences are ⁨Macintosh HD⁩ ▸ ⁨user ▸ ⁨userxyz ▸ ⁨Library⁩ ▸ ⁨Prefe...
by bn
Mon Mar 22, 2021 10:52 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Is the Text Field good enough for this ?
Replies: 9
Views: 740

Re: Is the Text Field good enough for this ?

I have not built the app to test it on mobile yet. but let's take this example, if I would ask some kids to writte a line poems, some using PC, tablets or a mobile to do so, I would need to find a way to count those 5 lines. :idea: :?: If I understand correctly you want to make sure there are 5 lin...
by bn
Wed Feb 10, 2021 12:19 am
Forum: Getting Started with LiveCode - Complete Beginners
Topic: A question about call by reference
Replies: 23
Views: 2142

Re: A question about call by reference

That is a not-so-insignificant improvement. I wonder if that would be something to suggest to the team as an improvement? Brian, these are pretty extrem cases in the IDE but they show nicely what @ can do when used in the right place. Maybe when the team has more time to look at stuff like this I w...
by bn
Mon Feb 08, 2021 7:09 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Random numbers with no duplicates
Replies: 7
Views: 687

Re: Random numbers with no duplicates

Hi Mike, something like this... on mouseUp repeat until the number of lines in tData is 6 put random(10) into tTest if tTest is not among the lines of tData then put tTest & cr after tData end if end repeat delete char -1 of tData -- a return -- the list is not orderd -- order list -- sort tData asc...
by bn
Mon Feb 08, 2021 3:00 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: A question about call by reference
Replies: 23
Views: 2142

Re: A question about call by reference

To make it easier to test passing parameters by reference or without for variables that change in between passing here is a stack to test without fiddling with the IDE as in the example above. Though that is a real world example. In the stack below you have the option to load some IDE stacks of diff...
by bn
Mon Feb 08, 2021 2:30 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: A question about call by reference
Replies: 23
Views: 2142

Re: A question about call by reference

......... As stated earlier, if you are not changing the value then there is probably not a huge cost since the engine does a copy on write. (In a tight loop with many calls you could achieve some speed gains by explicitly doing a pass by reference since the engine wouldn't need to set up the addit...
by bn
Mon Jan 18, 2021 2:28 am
Forum: Talking LiveCode
Topic: Not a number is a number, problem
Replies: 83
Views: 6141

Re: Not a number is a number, problem

Another way to force a string compare note if item 1 of inLine begins with aCode and (length(item 1 of inline) = length(aCode)) then on mouseUp pMouseBtnNum put "NAN,HTH,$42.70" into inLine put "NAN" into aCode get ((aCode is strictly a string) and ((item 1 of inLine) is strictly a string)) answer "...
by bn
Sun Jan 17, 2021 1:30 am
Forum: Talking LiveCode
Topic: Not a number is a number, problem
Replies: 83
Views: 6141

Re: Not a number is a number, problem

OK, maybe I have to explain. Infinitiy > NAN And at the same time NAN > Infinity Both are mathematically evaluated and both comparisons return true which is what I was alluding to. But who is to argue with infinity... Furthermore "2e2" is a number in Livecode and is smaller than Infinity. I just wan...
by bn
Sat Jan 16, 2021 8:09 pm
Forum: Talking LiveCode
Topic: Not a number is a number, problem
Replies: 83
Views: 6141

Re: Not a number is a number, problem

For your pleasure: on mouseUp put "Infinity" into tInf put "NAN" into tNan put tInf > tNan into tResult1 if tResult1 then put tNan & " is larger than " & tInf into tResult1 end if put tNan > tInf into tResult2 if tResult2 then put tInf & " is larger than " & tNan into tResult2 end if put "2e2" < tIn...
by bn
Wed Jan 13, 2021 3:30 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Various ways of matching a line
Replies: 14
Views: 3005

Re: Various ways of matching a line

Michael, I try to break this down a bit more hoping to make it a bit more clear when you code put word 3 of theLine into myArray[word 1 of theLine][word 2 of theLine] you create an array with 2 keys and 1 value. The keys are myArray[index][fruit] , the value is quality: myArray[index][fruit]quality ...
by bn
Wed Jan 13, 2021 3:11 pm
Forum: Getting Started with LiveCode - Complete Beginners
Topic: Various ways of matching a line
Replies: 14
Views: 3005

Re: Various ways of matching a line

Thank you very much. I can see that it works, but I'm having a hard time wrapping my head around it. Before you posted, I went ahead and made the functions with lineOffset, so at least that works too. Michael, which ever way you solve the problem I would take some moments to get the logic of the ar...

Go to advanced search