Re: Bard AI
Pardon my language, but this is wonderful. On Thu, Mar 23, 2023 at 15:42 Stephen Barncard wrote: > Holy crap > > On Thu, Mar 23, 2023 at 13:44 J. Landman Gay via use-livecode < > use-livecode@lists.runrev.com> wrote: > >> So I asked Bard to create a poem about LiveCode. The first drafts were >> just short lines of text >> that didn't even qualify as blank poetry, so I revised my request to ask >> it to make the poem rhyme. >> >> ** >> Sure! Here is a poem about the LiveCode coding language: >> >> LiveCode, oh LiveCode, >> You make coding so easy. >> With your natural English syntax, >> I can create what I please. >> >> I can build games and apps, >> Or websites and more. >> The possibilities are endless, >> With your simple yet powerful core. >> >> You're cross-platform and free, >> So anyone can use you. >> And you're backed by a passionate community, >> Who are always willing to help me through. >> >> LiveCode, oh LiveCode, >> You're the best coding language out there. >> With your help, I can create anything I imagine, >> And share it with the world without a care. >> ** >> >> It needs some work on meter but it's no worse than some human poems I've >> read. >> >> -- >> Jacqueline Landman Gay | jac...@hyperactivesw.com >> HyperActive Software | http://www.hyperactivesw.com >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your >> subscription preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode >> > -- > -- > Stephen Barncard - Sebastopol Ca. USA - > mixstream.org > -- -- Stephen Barncard - Sebastopol Ca. USA - mixstream.org ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Bard AI
Holy crap On Thu, Mar 23, 2023 at 13:44 J. Landman Gay via use-livecode < use-livecode@lists.runrev.com> wrote: > So I asked Bard to create a poem about LiveCode. The first drafts were > just short lines of text > that didn't even qualify as blank poetry, so I revised my request to ask > it to make the poem rhyme. > > ** > Sure! Here is a poem about the LiveCode coding language: > > LiveCode, oh LiveCode, > You make coding so easy. > With your natural English syntax, > I can create what I please. > > I can build games and apps, > Or websites and more. > The possibilities are endless, > With your simple yet powerful core. > > You're cross-platform and free, > So anyone can use you. > And you're backed by a passionate community, > Who are always willing to help me through. > > LiveCode, oh LiveCode, > You're the best coding language out there. > With your help, I can create anything I imagine, > And share it with the world without a care. > ** > > It needs some work on meter but it's no worse than some human poems I've > read. > > -- > Jacqueline Landman Gay | jac...@hyperactivesw.com > HyperActive Software | http://www.hyperactivesw.com > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > -- -- Stephen Barncard - Sebastopol Ca. USA - mixstream.org ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Bard AI
So I asked Bard to create a poem about LiveCode. The first drafts were just short lines of text that didn't even qualify as blank poetry, so I revised my request to ask it to make the poem rhyme. ** Sure! Here is a poem about the LiveCode coding language: LiveCode, oh LiveCode, You make coding so easy. With your natural English syntax, I can create what I please. I can build games and apps, Or websites and more. The possibilities are endless, With your simple yet powerful core. You're cross-platform and free, So anyone can use you. And you're backed by a passionate community, Who are always willing to help me through. LiveCode, oh LiveCode, You're the best coding language out there. With your help, I can create anything I imagine, And share it with the world without a care. ** It needs some work on meter but it's no worse than some human poems I've read. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Bard AI
I've been accepted into the test group for Google's new Bard AI, which is similar to ChatGPT. It's still experimental but looks promising. Google says it does not extract exact information directly from sources, but uses several to compile an original response to the prompt. Here's Bard's response to "Describe the LiveCode programming language": ** LiveCode is a programming language that is designed to be easy to learn and use. It is a cross-platform language, which means that it can be used to create applications that run on multiple different operating systems. LiveCode is also a rapid application development (RAD) language, which means that it can be used to create applications very quickly. LiveCode is a good choice for beginners because it is a relatively easy language to learn. It has a simple syntax and a large community of users and developers who can help you if you get stuck. LiveCode is also a good choice for experienced developers because it is a powerful language that can be used to create complex applications. Here are some of the features of LiveCode: * It is a cross-platform language. * It is a rapid application development (RAD) language. * It has a simple syntax. * It has a large community of users and developers. * It is a powerful language that can be used to create complex applications. If you are interested in learning more about LiveCode, you can visit the LiveCode website or the LiveCode Forum. ** Whenever it does actually quote a source there is a link included. This response had no links. Not bad but I would have liked to see more detail so I clicked the "get a new response" button: ** LiveCode is a cross-platform rapid application development runtime system inspired by HyperCard. It features the LiveCode Script programming language which belongs to the family of xTalk scripting languages like HyperCard's HyperTalk. The environment was introduced in 2001. The "Revolution" development system was based on the MetaCard engine technology which Runtime Revolution later acquired from MetaCard Corporation in 2003. The platform won the Macworld Annual Editor's Choice Award for "Best Development Software" in 2004. LiveCode's natural English-like syntax is easy for beginners to learn. Variables are typeless, and are typed at compile time based purely on context. This makes the language simple to read and maintain, with relatively minimal loss of speed. The language contains advanced features including associative arrays, regular expressions, multimedia, support for a variety of SQL databases, and TCP/IP libraries. The LiveCode engine supports several common image formats (including BMP, PNG, GIF, and JPEG,), anti-aliased vector graphics, HTML-style text hyperlinks, chained behaviors and embedded web browsers. LiveCode is a powerful and flexible language that can be used to create a wide variety of applications, from simple games and utilities to complex web applications and enterprise software. It is a great choice for both beginners and experienced developers, and it is a popular choice for schools and businesses. Here are some of the features of LiveCode: * Natural English-like syntax * Easy to learn and use * Powerful and flexible * Cross-platform * Wide variety of applications * Great for both beginners and experienced developers * Popular choice for schools and businesses ** Much better. This response included two links to Wikipedia articles. Google says Bard does not yet support coding examples but when it does I'll try it. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
Oh dear - replying to myself again :-) The 'itemDel' method still does the long search through the text - even though it does it at engine speed, and in neat tidy looking script. But, re-reading your earlier description, it occurred to me that (maybe) you are doing lots of different processing on the same bit of text. If that is the case, then it may be worth doing a single "reverse" operation at the start, and then doing everything as a 'forward' search. i.e. put the number of chars in tText into K put reverse(tText) into tRevText to find the enclosing strings from position 'm', we would do put offset(tClosingSting, tText, m) into t2 put K - offset( reverse(tOpeningString), tRevText, K-m) into t1 text you need is in char t1 to t2 of tText Should give you quick searches - IF you repeatedly process the same text. Alex. P.S. quickest 'reverse' function ? Might be put the number of chars in tText into K put K into N repeat for each char c in tText put c into tRev[N] subtract 1 from N end repeat combine tRev with empty Alex. On 23/03/2023 19:03, Alex Tweedly via use-livecode wrote: OK, I may be going in the wrong direction here, but put (the opening string) into temp set the itemDelimeter to temp put the number of chars in item 1 to -2 of theWholeText into theAnswer ?? Alex. On 23/03/2023 17:24, François via use-livecode wrote: Yes, this is the big picture. Plus, some environments may live within other environments. And yes, one of the things the app does all the time is finding matched opening strings and closing strings, like finding matched parentheses in a programming language. Fun, as you said! François Le 23 mars 2023 à 18:17, Craig Newman via use-livecode a écrit : Fun, fun… So if you collect ALL the opening and closing strings, and hopefully these never overlap, then each pair can be “ordered”. Now identifying each is just a matter of thinking in terms of “pairs” of offsets. You can then identify each by their “paired” position in the forward direction. Or am i missing it still? Craig On Mar 23, 2023, at 12:29 PM, François via use-livecode wrote: An example of when a backwards search would be useful is the following: In the app, you have to find command environments. Environments are delimited by an opening string and a closing string. Usually, I search forward for the opening string, then search for the closing string afterwards. Once this occurrence is processed, the app goes on with a forward search. Now another problem: I want to see in which environment a text position is in, i.e. finding the enclosing opening and closing strings. Looking for the closing string is a no brainer. Looking for the opening string is no more difficult if I can do a backwards search. However, if I can only search forward, I must start the search at the beginning of the text to scan all the occurrences of the opening string that stand before the text position (if any). The complexity of this approach is not the same as in the case where a backwards search is available. François Le 23 mars 2023 à 16:48, Craig Newman via use-livecode a écrit : Francois. I am sure you know what you have and what you need. But just for my curiosity, if I had to do what you want, I would have used the “offset” function and its “charsToSkip” parameter to find all instances of the text to find, and then use those values in sequence to work backwards. But then how do you know when to stop? Craig On Mar 23, 2023, at 11:30 AM, François via use-livecode wrote: The text source is not very big. However I implement transcoding from one language to another and I do an VERY large amount of search and replace. I think I have quite optimized my LC code but transcoding can take 5 minutes to do, and I need the whole process to chase unexpected bugs. This is using the forward search (offset) most of the time. Using a standalone app takes the time down to 4 minutes, which is not a sufficient gain for my usage. François Le 23 mars 2023 à 16:21, Craig Newman via use-livecode a écrit : Francois. Who wouldn’t? But unless you are working with VERY large datasets, I bet a handler would process quickly. Craig On Mar 23, 2023, at 10:58 AM, François via use-livecode wrote: @Ben Too bad… @ Craig I would rather have an optimized version, I do a lot of text processing in my app. Thanks to both of you! François Le 23 mars 2023 à 14:43, Craig Newman via use-livecode a écrit : @Ben. 20 years! Congratulations!. @Francois This can be scripted easily. Do you need help with that? Craig On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode wrote: https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this September!) Also https://quality.livecode.com/show_bug.cgi?id=8353 On 23/03/2023 11:35, François via use-livecode wrote: I would like to search for a string within another string, starting at a gi
Re: Is it possible to use a reverse direction for offset
OK, I may be going in the wrong direction here, but put (the opening string) into temp set the itemDelimeter to temp put the number of chars in item 1 to -2 of theWholeText into theAnswer ?? Alex. On 23/03/2023 17:24, François via use-livecode wrote: Yes, this is the big picture. Plus, some environments may live within other environments. And yes, one of the things the app does all the time is finding matched opening strings and closing strings, like finding matched parentheses in a programming language. Fun, as you said! François Le 23 mars 2023 à 18:17, Craig Newman via use-livecode a écrit : Fun, fun… So if you collect ALL the opening and closing strings, and hopefully these never overlap, then each pair can be “ordered”. Now identifying each is just a matter of thinking in terms of “pairs” of offsets. You can then identify each by their “paired” position in the forward direction. Or am i missing it still? Craig On Mar 23, 2023, at 12:29 PM, François via use-livecode wrote: An example of when a backwards search would be useful is the following: In the app, you have to find command environments. Environments are delimited by an opening string and a closing string. Usually, I search forward for the opening string, then search for the closing string afterwards. Once this occurrence is processed, the app goes on with a forward search. Now another problem: I want to see in which environment a text position is in, i.e. finding the enclosing opening and closing strings. Looking for the closing string is a no brainer. Looking for the opening string is no more difficult if I can do a backwards search. However, if I can only search forward, I must start the search at the beginning of the text to scan all the occurrences of the opening string that stand before the text position (if any). The complexity of this approach is not the same as in the case where a backwards search is available. François Le 23 mars 2023 à 16:48, Craig Newman via use-livecode a écrit : Francois. I am sure you know what you have and what you need. But just for my curiosity, if I had to do what you want, I would have used the “offset” function and its “charsToSkip” parameter to find all instances of the text to find, and then use those values in sequence to work backwards. But then how do you know when to stop? Craig On Mar 23, 2023, at 11:30 AM, François via use-livecode wrote: The text source is not very big. However I implement transcoding from one language to another and I do an VERY large amount of search and replace. I think I have quite optimized my LC code but transcoding can take 5 minutes to do, and I need the whole process to chase unexpected bugs. This is using the forward search (offset) most of the time. Using a standalone app takes the time down to 4 minutes, which is not a sufficient gain for my usage. François Le 23 mars 2023 à 16:21, Craig Newman via use-livecode a écrit : Francois. Who wouldn’t? But unless you are working with VERY large datasets, I bet a handler would process quickly. Craig On Mar 23, 2023, at 10:58 AM, François via use-livecode wrote: @Ben Too bad… @ Craig I would rather have an optimized version, I do a lot of text processing in my app. Thanks to both of you! François Le 23 mars 2023 à 14:43, Craig Newman via use-livecode a écrit : @Ben. 20 years! Congratulations!. @Francois This can be scripted easily. Do you need help with that? Craig On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode wrote: https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this September!) Also https://quality.livecode.com/show_bug.cgi?id=8353 On 23/03/2023 11:35, François via use-livecode wrote: I would like to search for a string within another string, starting at a given position, but backward. In some languages, you can achieve that by providing a negative number for the initial position of the search. Is this possible in LiveCode? TIA François ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.c
Re: Is it possible to use a reverse direction for offset
Yes, this is the big picture. Plus, some environments may live within other environments. And yes, one of the things the app does all the time is finding matched opening strings and closing strings, like finding matched parentheses in a programming language. Fun, as you said! François > Le 23 mars 2023 à 18:17, Craig Newman via use-livecode > a écrit : > > Fun, fun… > > So if you collect ALL the opening and closing strings, and hopefully these > never overlap, then each pair can be “ordered”. Now identifying each is just > a matter of thinking in terms of “pairs” of offsets. You can then identify > each by their “paired” position in the forward direction. > > Or am i missing it still? > > Craig > >> On Mar 23, 2023, at 12:29 PM, François via use-livecode >> wrote: >> >> An example of when a backwards search would be useful is the following: >> >> In the app, you have to find command environments. Environments are >> delimited by an opening string and a closing string. >> >> Usually, I search forward for the opening string, then search for the >> closing string afterwards. Once this occurrence is processed, the app goes >> on with a forward search. >> >> Now another problem: I want to see in which environment a text position is >> in, i.e. finding the enclosing opening and closing strings. >> >> Looking for the closing string is a no brainer. Looking for the opening >> string is no more difficult if I can do a backwards search. >> >> However, if I can only search forward, I must start the search at the >> beginning of the text to scan all the occurrences of the opening string that >> stand before the text position (if any). The complexity of this approach is >> not the same as in the case where a backwards search is available. >> >> François >> >>> Le 23 mars 2023 à 16:48, Craig Newman via use-livecode >>> a écrit : >>> >>> Francois. >>> >>> I am sure you know what you have and what you need. >>> >>> But just for my curiosity, if I had to do what you want, I would have used >>> the “offset” function and its “charsToSkip” parameter to find all instances >>> of the text to find, and then use those values in sequence to work >>> backwards. But then how do you know when to stop? >>> >>> Craig >>> On Mar 23, 2023, at 11:30 AM, François via use-livecode wrote: The text source is not very big. However I implement transcoding from one language to another and I do an VERY large amount of search and replace. I think I have quite optimized my LC code but transcoding can take 5 minutes to do, and I need the whole process to chase unexpected bugs. This is using the forward search (offset) most of the time. Using a standalone app takes the time down to 4 minutes, which is not a sufficient gain for my usage. François > Le 23 mars 2023 à 16:21, Craig Newman via use-livecode > a écrit : > > Francois. > > Who wouldn’t? > > But unless you are working with VERY large datasets, I bet a handler > would process quickly. > > Craig > >> On Mar 23, 2023, at 10:58 AM, François via use-livecode >> wrote: >> >> @Ben >> >> Too bad… >> >> @ Craig >> >> I would rather have an optimized version, I do a lot of text processing >> in my app. >> >> Thanks to both of you! >> François >> >>> Le 23 mars 2023 à 14:43, Craig Newman via use-livecode >>> a écrit : >>> >>> @Ben. >>> >>> 20 years! Congratulations!. >>> >>> @Francois >>> >>> This can be scripted easily. Do you need help with that? >>> >>> Craig >>> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode wrote: https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this September!) Also https://quality.livecode.com/show_bug.cgi?id=8353 On 23/03/2023 11:35, François via use-livecode wrote: > I would like to search for a string within another string, starting > at a given position, but backward. > In some languages, you can achieve that by providing a negative > number for the initial position of the search. > Is this possible in LiveCode? > TIA > François > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your sub
Re: Is it possible to use a reverse direction for offset
Fun, fun… So if you collect ALL the opening and closing strings, and hopefully these never overlap, then each pair can be “ordered”. Now identifying each is just a matter of thinking in terms of “pairs” of offsets. You can then identify each by their “paired” position in the forward direction. Or am i missing it still? Craig > On Mar 23, 2023, at 12:29 PM, François via use-livecode > wrote: > > An example of when a backwards search would be useful is the following: > > In the app, you have to find command environments. Environments are delimited > by an opening string and a closing string. > > Usually, I search forward for the opening string, then search for the closing > string afterwards. Once this occurrence is processed, the app goes on with a > forward search. > > Now another problem: I want to see in which environment a text position is > in, i.e. finding the enclosing opening and closing strings. > > Looking for the closing string is a no brainer. Looking for the opening > string is no more difficult if I can do a backwards search. > > However, if I can only search forward, I must start the search at the > beginning of the text to scan all the occurrences of the opening string that > stand before the text position (if any). The complexity of this approach is > not the same as in the case where a backwards search is available. > > François > >> Le 23 mars 2023 à 16:48, Craig Newman via use-livecode >> a écrit : >> >> Francois. >> >> I am sure you know what you have and what you need. >> >> But just for my curiosity, if I had to do what you want, I would have used >> the “offset” function and its “charsToSkip” parameter to find all instances >> of the text to find, and then use those values in sequence to work >> backwards. But then how do you know when to stop? >> >> Craig >> >>> On Mar 23, 2023, at 11:30 AM, François via use-livecode >>> wrote: >>> >>> The text source is not very big. >>> >>> However I implement transcoding from one language to another and I do an >>> VERY large amount of search and replace. >>> >>> I think I have quite optimized my LC code but transcoding can take 5 >>> minutes to do, and I need the whole process to chase unexpected bugs. This >>> is using the forward search (offset) most of the time. >>> >>> Using a standalone app takes the time down to 4 minutes, which is not a >>> sufficient gain for my usage. >>> >>> François >>> Le 23 mars 2023 à 16:21, Craig Newman via use-livecode a écrit : Francois. Who wouldn’t? But unless you are working with VERY large datasets, I bet a handler would process quickly. Craig > On Mar 23, 2023, at 10:58 AM, François via use-livecode > wrote: > > @Ben > > Too bad… > > @ Craig > > I would rather have an optimized version, I do a lot of text processing > in my app. > > Thanks to both of you! > François > >> Le 23 mars 2023 à 14:43, Craig Newman via use-livecode >> a écrit : >> >> @Ben. >> >> 20 years! Congratulations!. >> >> @Francois >> >> This can be scripted easily. Do you need help with that? >> >> Craig >> >>> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode >>> wrote: >>> >>> https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this >>> September!) >>> >>> Also >>> https://quality.livecode.com/show_bug.cgi?id=8353 >>> >>> >>> >>> On 23/03/2023 11:35, François via use-livecode wrote: I would like to search for a string within another string, starting at a given position, but backward. In some languages, you can achieve that by providing a negative number for the initial position of the search. Is this possible in LiveCode? TIA François ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your >> subscription preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@list
Re: Is it possible to use a reverse direction for offset
An example of when a backwards search would be useful is the following: In the app, you have to find command environments. Environments are delimited by an opening string and a closing string. Usually, I search forward for the opening string, then search for the closing string afterwards. Once this occurrence is processed, the app goes on with a forward search. Now another problem: I want to see in which environment a text position is in, i.e. finding the enclosing opening and closing strings. Looking for the closing string is a no brainer. Looking for the opening string is no more difficult if I can do a backwards search. However, if I can only search forward, I must start the search at the beginning of the text to scan all the occurrences of the opening string that stand before the text position (if any). The complexity of this approach is not the same as in the case where a backwards search is available. François > Le 23 mars 2023 à 16:48, Craig Newman via use-livecode > a écrit : > > Francois. > > I am sure you know what you have and what you need. > > But just for my curiosity, if I had to do what you want, I would have used > the “offset” function and its “charsToSkip” parameter to find all instances > of the text to find, and then use those values in sequence to work backwards. > But then how do you know when to stop? > > Craig > >> On Mar 23, 2023, at 11:30 AM, François via use-livecode >> wrote: >> >> The text source is not very big. >> >> However I implement transcoding from one language to another and I do an >> VERY large amount of search and replace. >> >> I think I have quite optimized my LC code but transcoding can take 5 minutes >> to do, and I need the whole process to chase unexpected bugs. This is using >> the forward search (offset) most of the time. >> >> Using a standalone app takes the time down to 4 minutes, which is not a >> sufficient gain for my usage. >> >> François >> >>> Le 23 mars 2023 à 16:21, Craig Newman via use-livecode >>> a écrit : >>> >>> Francois. >>> >>> Who wouldn’t? >>> >>> But unless you are working with VERY large datasets, I bet a handler would >>> process quickly. >>> >>> Craig >>> On Mar 23, 2023, at 10:58 AM, François via use-livecode wrote: @Ben Too bad… @ Craig I would rather have an optimized version, I do a lot of text processing in my app. Thanks to both of you! François > Le 23 mars 2023 à 14:43, Craig Newman via use-livecode > a écrit : > > @Ben. > > 20 years! Congratulations!. > > @Francois > > This can be scripted easily. Do you need help with that? > > Craig > >> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode >> wrote: >> >> https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this >> September!) >> >> Also >> https://quality.livecode.com/show_bug.cgi?id=8353 >> >> >> >> On 23/03/2023 11:35, François via use-livecode wrote: >>> I would like to search for a string within another string, starting at >>> a given position, but backward. >>> In some languages, you can achieve that by providing a negative number >>> for the initial position of the search. >>> Is this possible in LiveCode? >>> TIA >>> François >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your >> subscription preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.
Re: Is it possible to use a reverse direction for offset
Francois. I am sure you know what you have and what you need. But just for my curiosity, if I had to do what you want, I would have used the “offset” function and its “charsToSkip” parameter to find all instances of the text to find, and then use those values in sequence to work backwards. But then how do you know when to stop? Craig > On Mar 23, 2023, at 11:30 AM, François via use-livecode > wrote: > > The text source is not very big. > > However I implement transcoding from one language to another and I do an VERY > large amount of search and replace. > > I think I have quite optimized my LC code but transcoding can take 5 minutes > to do, and I need the whole process to chase unexpected bugs. This is using > the forward search (offset) most of the time. > > Using a standalone app takes the time down to 4 minutes, which is not a > sufficient gain for my usage. > > François > >> Le 23 mars 2023 à 16:21, Craig Newman via use-livecode >> a écrit : >> >> Francois. >> >> Who wouldn’t? >> >> But unless you are working with VERY large datasets, I bet a handler would >> process quickly. >> >> Craig >> >>> On Mar 23, 2023, at 10:58 AM, François via use-livecode >>> wrote: >>> >>> @Ben >>> >>> Too bad… >>> >>> @ Craig >>> >>> I would rather have an optimized version, I do a lot of text processing in >>> my app. >>> >>> Thanks to both of you! >>> François >>> Le 23 mars 2023 à 14:43, Craig Newman via use-livecode a écrit : @Ben. 20 years! Congratulations!. @Francois This can be scripted easily. Do you need help with that? Craig > On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode > wrote: > > https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this > September!) > > Also > https://quality.livecode.com/show_bug.cgi?id=8353 > > > > On 23/03/2023 11:35, François via use-livecode wrote: >> I would like to search for a string within another string, starting at a >> given position, but backward. >> In some languages, you can achieve that by providing a negative number >> for the initial position of the search. >> Is this possible in LiveCode? >> TIA >> François >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your >> subscription preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
The text source is not very big. However I implement transcoding from one language to another and I do an VERY large amount of search and replace. I think I have quite optimized my LC code but transcoding can take 5 minutes to do, and I need the whole process to chase unexpected bugs. This is using the forward search (offset) most of the time. Using a standalone app takes the time down to 4 minutes, which is not a sufficient gain for my usage. François > Le 23 mars 2023 à 16:21, Craig Newman via use-livecode > a écrit : > > Francois. > > Who wouldn’t? > > But unless you are working with VERY large datasets, I bet a handler would > process quickly. > > Craig > >> On Mar 23, 2023, at 10:58 AM, François via use-livecode >> wrote: >> >> @Ben >> >> Too bad… >> >> @ Craig >> >> I would rather have an optimized version, I do a lot of text processing in >> my app. >> >> Thanks to both of you! >> François >> >>> Le 23 mars 2023 à 14:43, Craig Newman via use-livecode >>> a écrit : >>> >>> @Ben. >>> >>> 20 years! Congratulations!. >>> >>> @Francois >>> >>> This can be scripted easily. Do you need help with that? >>> >>> Craig >>> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode wrote: https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this September!) Also https://quality.livecode.com/show_bug.cgi?id=8353 On 23/03/2023 11:35, François via use-livecode wrote: > I would like to search for a string within another string, starting at a > given position, but backward. > In some languages, you can achieve that by providing a negative number > for the initial position of the search. > Is this possible in LiveCode? > TIA > François > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
Francois. Who wouldn’t? But unless you are working with VERY large datasets, I bet a handler would process quickly. Craig > On Mar 23, 2023, at 10:58 AM, François via use-livecode > wrote: > > @Ben > > Too bad… > > @ Craig > > I would rather have an optimized version, I do a lot of text processing in my > app. > > Thanks to both of you! > François > >> Le 23 mars 2023 à 14:43, Craig Newman via use-livecode >> a écrit : >> >> @Ben. >> >> 20 years! Congratulations!. >> >> @Francois >> >> This can be scripted easily. Do you need help with that? >> >> Craig >> >>> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode >>> wrote: >>> >>> https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this >>> September!) >>> >>> Also >>> https://quality.livecode.com/show_bug.cgi?id=8353 >>> >>> >>> >>> On 23/03/2023 11:35, François via use-livecode wrote: I would like to search for a string within another string, starting at a given position, but backward. In some languages, you can achieve that by providing a negative number for the initial position of the search. Is this possible in LiveCode? TIA François ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
@Ben Too bad… @ Craig I would rather have an optimized version, I do a lot of text processing in my app. Thanks to both of you! François > Le 23 mars 2023 à 14:43, Craig Newman via use-livecode > a écrit : > > @Ben. > > 20 years! Congratulations!. > > @Francois > > This can be scripted easily. Do you need help with that? > > Craig > >> On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode >> wrote: >> >> https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this >> September!) >> >> Also >> https://quality.livecode.com/show_bug.cgi?id=8353 >> >> >> >> On 23/03/2023 11:35, François via use-livecode wrote: >>> I would like to search for a string within another string, starting at a >>> given position, but backward. >>> In some languages, you can achieve that by providing a negative number for >>> the initial position of the search. >>> Is this possible in LiveCode? >>> TIA >>> François >>> ___ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
@Ben. 20 years! Congratulations!. @Francois This can be scripted easily. Do you need help with that? Craig > On Mar 23, 2023, at 8:21 AM, Ben Rubinstein via use-livecode > wrote: > > https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this > September!) > > Also > https://quality.livecode.com/show_bug.cgi?id=8353 > > > > On 23/03/2023 11:35, François via use-livecode wrote: >> I would like to search for a string within another string, starting at a >> given position, but backward. >> In some languages, you can achieve that by providing a negative number for >> the initial position of the search. >> Is this possible in LiveCode? >> TIA >> François >> ___ >> use-livecode mailing list >> use-livecode@lists.runrev.com >> Please visit this url to subscribe, unsubscribe and manage your subscription >> preferences: >> http://lists.runrev.com/mailman/listinfo/use-livecode > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Is it possible to use a reverse direction for offset
https://quality.livecode.com/show_bug.cgi?id=584 (20th anniversary this September!) Also https://quality.livecode.com/show_bug.cgi?id=8353 On 23/03/2023 11:35, François via use-livecode wrote: I would like to search for a string within another string, starting at a given position, but backward. In some languages, you can achieve that by providing a negative number for the initial position of the search. Is this possible in LiveCode? TIA François ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Is it possible to use a reverse direction for offset
I would like to search for a string within another string, starting at a given position, but backward. In some languages, you can achieve that by providing a negative number for the initial position of the search. Is this possible in LiveCode? TIA François ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode