Re: Word delimiters

2017-06-12 Thread Mark Waddingham via use-livecode

On 2017-06-13 01:18, Devin Asay via use-livecode wrote:

Fixed.

https://github.com/livecode/livecode/pull/5592


Thanks Devin and Henry :)

Now if I do the same thing with Bug ..., Bug ..., Bug , ... and go 
back to bed, will I wake up to find them all fixed in a similar fashion? 
;)


Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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: Word delimiters

2017-06-12 Thread Devin Asay via use-livecode
Added cross reference to dictionary entry for  ‘words’ keyword, for good 
measure.

https://github.com/livecode/livecode/pull/5593

Devin

On Jun 12, 2017, at 5:18 PM, Devin Asay via use-livecode 
> wrote:

Fixed.

https://github.com/livecode/livecode/pull/5592


On Jun 12, 2017, at 3:13 PM, hlowe via use-livecode 
> wrote:

Done. http://quality.livecode.com/show_bug.cgi?id=19855

Henry


Devin Asay
Director
Office of Digital Humanities
Brigham Young University

___
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: Word delimiters

2017-06-12 Thread Devin Asay via use-livecode
Fixed.

https://github.com/livecode/livecode/pull/5592


On Jun 12, 2017, at 3:13 PM, hlowe via use-livecode 
<use-livecode@lists.runrev.com<mailto:use-livecode@lists.runrev.com>> wrote:

Done. http://quality.livecode.com/show_bug.cgi?id=19855

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709p4715746.html
Sent from the Revolution - User mailing list archive at 
Nabble.com<http://Nabble.com>.

___
use-livecode mailing list
use-livecode@lists.runrev.com<mailto: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

Devin Asay
Director
Office of Digital Humanities
Brigham Young University

___
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: Word delimiters

2017-06-12 Thread hlowe via use-livecode
Done. http://quality.livecode.com/show_bug.cgi?id=19855

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709p4715746.html
Sent from the Revolution - User mailing list archive at Nabble.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: Word delimiters

2017-06-12 Thread Mark Waddingham via use-livecode

On 2017-06-12 05:12, hlowe via use-livecode wrote:
Interestingly, there is no cross-refernce to TrueWord from the Word 
entry in
the 8.1.4 dictionary, though there is a cross-reference from TrueWord 
to

Word.


If you have a moment to file a bug in our quality center about that, it 
will get put on the list of docs amendments to make. We just need to 
make the xrefs symmetrical :)


Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Everyone can create apps

___
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: Word delimiters

2017-06-12 Thread Paul Dupuis via use-livecode
On 6/11/2017 11:12 PM, hlowe via use-livecode wrote:
> Interestingly, there is no cross-refernce to TrueWord from the Word entry in
> the 8.1.4 dictionary, though there is a cross-reference from TrueWord to
> Word. 

I would say this is a dictionary "bug" as there should be a cross
reference to TrueWord in the Word entry. If you know GitHub, you could
update the dictionary yourself (I don't know how) or submit a bug report
to http://quality.livecode.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: Word delimiters

2017-06-11 Thread hlowe via use-livecode
Thank you, again, for pointing me towards TrueWord which (according to the
dictionary):

"Designates a string as part of a chunk expression, delimited by Unicode
word breaks, as determined by the ICU Library."

Using TrueWord instead of word in my 8.1.4 code, fixed the problems that I
was encountereing with word chunk identification when the "word" was
prefixed or suffixed with parens characters or punctuation. There appears to
be little performance impact is using "TrueWord" in place of "word" when
searching very large texts (10+ MB).

Interestingly, there is no cross-refernce to TrueWord from the Word entry in
the 8.1.4 dictionary, though there is a cross-reference from TrueWord to
Word. 

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709p4715715.html
Sent from the Revolution - User mailing list archive at Nabble.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: Word delimiters

2017-06-11 Thread hlowe via use-livecode
Thank you. I will try using trueWord.

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709p4715711.html
Sent from the Revolution - User mailing list archive at Nabble.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: Word delimiters

2017-06-10 Thread Paul Dupuis via use-livecode
LiveCode 7+ see trueWord in the dictionary



On 6/10/2017 7:38 PM, hlowe via use-livecode wrote:
> Livecode defines a word as:
>
> "A word is delimited by one or more spaces, tabs, or returns, or is enclosed
> by double quotes."
>
> Generally this works well but if I have text in which one or more words are
> contained within either round brackets "(word1 word2)" or square brackets
> "[word1 word2]" the paren characters are considered part of the word.
>
> For example try this from the message box:
>
> "answer word 4 of "word1 (word2 word3) [word4 word5]"
>  the result is "[word4"
>  
> Thus searching for specific word chunks within text fails if the word is
> contained within a round or square bracket.
>
> For example:
>
> repeat for each word tWord in "red (blue green) [orange purple]"
> if tWord is "orange" then answer "found" 
> end repeat
>
> Though "orange" is a word (by general definition) in the text, it is not
> found.
>
> The same issue arises if there are certain punctuation characters at the end
> of a word e.g "orange;"
>
> Ideally one could define a set of comma-delimited characters that are
> considered word delimiters in the same way that we can (temporarily) change
> the itemDelimiter character:
>
> e.g. set the WordDelimiters to "~,(,),{,},[,],;,:,comma, return,space,tab"
>
> Similar to the itemDelimiter property, this property would be reset to the
> default when the handler completes.
>
> Perhaps there is already a solution to this that I don't know about? Yes,
> one can preprocess the input text to remove parens and certain punctuation
> characters but having the option for LiveCode to recognize them as word
> delimiters would be more elegant (IMHO).
>
> Henry
>
>
>
> --
> View this message in context: 
> http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709.html
> Sent from the Revolution - User mailing list archive at Nabble.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
>


___
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


Word delimiters

2017-06-10 Thread hlowe via use-livecode
Livecode defines a word as:

"A word is delimited by one or more spaces, tabs, or returns, or is enclosed
by double quotes."

Generally this works well but if I have text in which one or more words are
contained within either round brackets "(word1 word2)" or square brackets
"[word1 word2]" the paren characters are considered part of the word.

For example try this from the message box:

"answer word 4 of "word1 (word2 word3) [word4 word5]"
 the result is "[word4"
 
Thus searching for specific word chunks within text fails if the word is
contained within a round or square bracket.

For example:

repeat for each word tWord in "red (blue green) [orange purple]"
if tWord is "orange" then answer "found" 
end repeat

Though "orange" is a word (by general definition) in the text, it is not
found.

The same issue arises if there are certain punctuation characters at the end
of a word e.g "orange;"

Ideally one could define a set of comma-delimited characters that are
considered word delimiters in the same way that we can (temporarily) change
the itemDelimiter character:

e.g. set the WordDelimiters to "~,(,),{,},[,],;,:,comma, return,space,tab"

Similar to the itemDelimiter property, this property would be reset to the
default when the handler completes.

Perhaps there is already a solution to this that I don't know about? Yes,
one can preprocess the input text to remove parens and certain punctuation
characters but having the option for LiveCode to recognize them as word
delimiters would be more elegant (IMHO).

Henry



--
View this message in context: 
http://runtime-revolution.278305.n4.nabble.com/Word-delimiters-tp4715709.html
Sent from the Revolution - User mailing list archive at Nabble.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