Re: Stripping styling from the clipboard...

2018-06-25 Thread Bob Sneidar via use-livecode
I always run code from the SE through a plain text editor before pasting on this list. Bob S > On Jun 24, 2018, at 07:04 , Richmond Mathewson via use-livecode > wrote: > >> >> Richmond. why does your code paste that way? >> >> > > I don't know: looks terrible! > > Over "here" on Th

Re: Stripping styling from the clipboard...

2018-06-25 Thread Bob Sneidar via use-livecode
Or it's being trapped/interceped somewhere earlier. Have you tried fresh launch (no libraries running) and a new stack? Bob S > On Jun 23, 2018, at 13:07 , Paul Dupuis via use-livecode > wrote: > > If I just have a pasteKey handler with a beep (or anything else) as the > sole instruction, t

Re: Stripping styling from the clipboard...

2018-06-25 Thread Tom Glod via use-livecode
I see...good to know. thanks J On Sun, Jun 24, 2018 at 10:39 AM, J. Landman Gay via use-livecode < use-livecode@lists.runrev.com> wrote: > Using an intermediate text editor also works, and would take care of any > UTF8 conversion too if that's causing issues. But since you're in LC > already

Re: Stripping styling from the clipboard...

2018-06-24 Thread J. Landman Gay via use-livecode
Using an intermediate text editor also works, and would take care of any UTF8 conversion too if that's causing issues. But since you're in LC already it might be more convenient to have a handler in a backscript or a plugin that would do it. -- Jacqueline Landman Gay | jac...@hyperactivesw.com

Re: Stripping styling from the clipboard...

2018-06-24 Thread Richmond Mathewson via use-livecode
Well that is a pain in the bum! I suppose I should go through an intermediate stage using a plain-vanilla text editor. Richmond. On 24/6/2018 8:19 am, J. Landman Gay via use-livecode wrote: It happens when a colorized handler is copied directly from the script editor and pasted into a list r

Re: Stripping styling from the clipboard...

2018-06-24 Thread Richmond Mathewson via use-livecode
Richmond. why does your code paste that way? I don't know: looks terrible! Over "here" on ThunderBird e-mail client on MacOS 10.7.5 that code was pasted DIRECTLY from the LiveCode scriptEditor . . . Richmond. ___ use-livecode mailing list u

Re: Stripping styling from the clipboard...

2018-06-23 Thread J. Landman Gay via use-livecode
It happens when a colorized handler is copied directly from the script editor and pasted into a list response. The list only understands plain text, and styled text confuses it. I'm not sure if it happens on all platforms but we've seen it before in other posts. Brian's plaintext handler would

Re: Stripping styling from the clipboard...

2018-06-23 Thread Tom Glod via use-livecode
sorry Paul...my bad. Richmond. why does your code paste that way? On Sat, Jun 23, 2018 at 7:59 PM, Paul Dupuis via use-livecode < use-livecode@lists.runrev.com> wrote: > The code below with no spaces between the works is Richmonds > > On 6/23/2018 5:58 PM, Tom Glod via use-livecode wrote: >

Re: Stripping styling from the clipboard...

2018-06-23 Thread Paul Dupuis via use-livecode
The code below with no spaces between the works is Richmonds On 6/23/2018 5:58 PM, Tom Glod via use-livecode wrote: > Paul...may I ask you why your code pasting is the way it is ?...is there > some kind of practical reason for it being that way?...sure is harder to > read that way. > > On Sat, Jun

Re: Stripping styling from the clipboard...

2018-06-23 Thread James At The Hale via use-livecode
>From the dictionary... > The LiveCode development environment traps the pasteKey message, unless > "Suspend LiveCode UI" is turned on in the Development menu. This means that > the pasteKey message is not received by a stack if it's running in the > development environment. Could this be why

Re: Stripping styling from the clipboard...

2018-06-23 Thread Tom Glod via use-livecode
Paul...may I ask you why your code pasting is the way it is ?...is there some kind of practical reason for it being that way?...sure is harder to read that way. On Sat, Jun 23, 2018 at 5:55 PM, Paul Dupuis via use-livecode < use-livecode@lists.runrev.com> wrote: > Okay, I missed that in the entry

Re: Stripping styling from the clipboard...

2018-06-23 Thread Paul Dupuis via use-livecode
Okay, I missed that in the entry. That explains why the pasteKey message wasn't working. I am all set now. Thank you. On 6/23/2018 5:15 PM, Tore Nilsen via use-livecode wrote: > >From the dictionary: > > The LiveCode development environment traps the pasteKey message <>, unless > "Suspend LiveC

Re: Stripping styling from the clipboard...

2018-06-23 Thread Brian Milby via use-livecode
Nice catch Tore. My original code was addressing a different couple of problems. The first was that when you attempted to populate the clipboard with plain text that LC would also put an HTML version on that would cause issues with paste in other apps. The second is designed to adjust the HTML

Re: Stripping styling from the clipboard...

2018-06-23 Thread Tore Nilsen via use-livecode
>From the dictionary: The LiveCode development environment traps the pasteKey message <>, unless "Suspend LiveCode UI" is turned on in the Development menu. This means that the pasteKeymessage <> is not received by a stack <> if it's running in the development environment <>. So if you are try

Re: Stripping styling from the clipboard...

2018-06-23 Thread Richmond Mathewson via use-livecode
Strike that last remark. BUT: that script expects one to press the CONTROL key on the Mac rather than the COMMAND key one usually uses to PASTE, so how that can be achieved on a Windows or a Linux machine I just don't know. Richmond. On 23/6/2018 11:39 pm, Richmond Mathewson wrote: Oh: and j

Re: Stripping styling from the clipboard...

2018-06-23 Thread Richmond Mathewson via use-livecode
Oh: and just to make things even odder than usual, it only works when the fild "ff1" does NOT have focus (i.e. the cursor is NOT in the field). Richmond. On 23/6/2018 11:38 pm, Richmond Mathewson wrote: However, I, at least, am experiencing great joy just at present as this: oncontrolKeyDown K

Re: Stripping styling from the clipboard...

2018-06-23 Thread Richmond Mathewson via use-livecode
However, I, at least, am experiencing great joy just at present as this: oncontrolKeyDown KEE ifKEE is "V" then puttheclipboardDataintofld "ff1" else passcontrolKeyDown endif endcontrolKeyDown popped UNSTYLED text into fld "ff1" on MacOS 10.7.5 LiveCode 8.1.10 Your mileage m

Re: Stripping styling from the clipboard...

2018-06-23 Thread Richmond Mathewson via use-livecode
Indeed: over "here" on MacOS 10.7.5 Livecode 8.1.10 the pasteKey command seems to be non-functional. Richmond. On 23/6/2018 11:07 pm, Paul Dupuis via use-livecode wrote: Thank you for this. However, it appears my problem is not with converting the clipboard from styled text to plain text, but

Re: Stripping styling from the clipboard...

2018-06-23 Thread Richmond Mathewson via use-livecode
Hey, Wow, it's the Richmond school of shovels and primitive stuff at its worst. If I have a field that conatins some styled text (let's call it "ff1"), and I want to shift it with its styling removed into another field (let's call it "ff2") then this does the trick in a button: onmouseUp get

Re: Stripping styling from the clipboard...

2018-06-23 Thread Paul Dupuis via use-livecode
Thank you for this. However, it appears my problem is not with converting the clipboard from styled text to plain text, but with the "pasteKey" message. In LC9.0.0 under Windows 8.1, I create a new text stack and add and empty field and place the following handler in EITHER the card or stack scri

Re: Stripping styling from the clipboard...

2018-06-23 Thread Brian Milby via use-livecode
https://github.com/bwmilby/lc-misc/blob/master/ClipboardHelper/clipboardhelper.livecodescript Check out this handler. I can answer questions about it this evening if needed. On Jun 23, 2018, 9:18 AM -0500, Paul Dupuis via use-livecode , wrote: > Using LC9, I want to add a "paste without formattin

Stripping styling from the clipboard...

2018-06-23 Thread Paul Dupuis via use-livecode
Using LC9, I want to add a "paste without formatting" (as seen in may browser edit menus) command and I can't see to figure out how to do it. My most recent attempt of many still pastes formatted text (with underlining, bolding, italics, fonts, colors, etc. in place) *on*pasteKey *-- remove forma

Re: Stripping

2016-04-02 Thread Klaus major-k
Hi Jaqueline, > Am 02.04.2016 um 20:00 schrieb J. Landman Gay : > > On 4/2/2016 12:44 PM, Klaus major-k wrote: >> yep, but the CRs had been in his database records and not (yet) in Livecode! >> So he did not understand the real problem at that point. > And he still doesn't. Maybe I'll go poke him

Re: Stripping

2016-04-02 Thread J. Landman Gay
On 4/2/2016 12:44 PM, Klaus major-k wrote: yep, but the CRs had been in his database records and not (yet) in Livecode! So he did not understand the real problem at that point. And he still doesn't. Maybe I'll go poke him a little bit more. -- Jacqueline Landman Gay | jac...@hypera

Re: Stripping

2016-04-02 Thread Klaus major-k
Hi Richmond, > ... reading the thread may help! 8-) >>> I read the thread. The method in my stack can just as easily be used with >>> a string that is going into a datagrid. >> yep, but that really has nothing to do with the problem discussed in the >> thread. > > I answered the chap'

Re: Stripping

2016-04-02 Thread RM
On 2.04.2016 20:33, Klaus major-k wrote: Hi Richmond, Am 02.04.2016 um 19:30 schrieb RM : On 2.04.2016 20:27, Klaus major-k wrote: Hi Richmond, Am 02.04.2016 um 19:20 schrieb RM : There's been a bit of a "Hoo Haa" on the Forum about stripping out carriage

Re: Stripping

2016-04-02 Thread Klaus major-k
Hi Richmond, > Am 02.04.2016 um 19:30 schrieb RM : > > On 2.04.2016 20:27, Klaus major-k wrote: >> Hi Richmond, >> >>> Am 02.04.2016 um 19:20 schrieb RM : >>> >>> There's been a bit of a "Hoo Haa" on the Forum about stri

Re: Stripping

2016-04-02 Thread RM
On 2.04.2016 20:27, Klaus major-k wrote: Hi Richmond, Am 02.04.2016 um 19:20 schrieb RM : There's been a bit of a "Hoo Haa" on the Forum about stripping out carriage returns: http://forums.livecode.com/viewtopic.php?f=7&t=26929&p=140516#p140516 I'm not sure

Re: Stripping

2016-04-02 Thread Klaus major-k
Hi Richmond, > Am 02.04.2016 um 19:20 schrieb RM : > > There's been a bit of a "Hoo Haa" on the Forum about stripping out carriage > returns: > http://forums.livecode.com/viewtopic.php?f=7&t=26929&p=140516#p140516 > I'm not sure why. reading the

Stripping

2016-04-02 Thread RM
There's been a bit of a "Hoo Haa" on the Forum about stripping out carriage returns: http://forums.livecode.com/viewtopic.php?f=7&t=26929&p=140516#p140516 I'm not sure why. Richmond. ___ use-livecode mailing list u

Re: Stripping Returns

2014-11-19 Thread Jerry Jensen
rry. > > The variable accum had a length of 110K, the field truncated that to 65-odd > K, the reload just reflected what was in the field. > > Craig > > -Original Message- > From: Jerry Jensen > To: How to use LiveCode > Sent: Wed, Nov 19, 2014 3:43 pm

Re: Stripping Returns

2014-11-19 Thread dunbarx
Jerry. The variable accum had a length of 110K, the field truncated that to 65-odd K, the reload just reflected what was in the field. Craig -Original Message- From: Jerry Jensen To: How to use LiveCode Sent: Wed, Nov 19, 2014 3:43 pm Subject: Re: Stripping Returns On Nov 19

Re: Stripping Returns

2014-11-19 Thread Jerry Jensen
On Nov 19, 2014, at 12:32 PM, J. Landman Gay wrote: > On 11/19/2014, 2:14 PM, J. Landman Gay wrote: >> The text is truncated, not simply not displayed: > > Mystery solved. I was testing in LC 7.0: > > http://quality.runrev.com/show_bug.cgi?id=13508 And I was testing using LC 6.7 end curiosit

Re: Stripping Returns

2014-11-19 Thread Jerry Jensen
On Nov 19, 2014, at 12:14 PM, J. Landman Gay wrote: > Curiosity made me test: > > on setup > repeat until len(tStr) > 66000 >put any word of the colornames & space after tStr > end repeat > put last word of tStr -- for reference later > put tStr into fld 1 > end setup > > The field is a

Re: Stripping Returns

2014-11-19 Thread J. Landman Gay
On 11/19/2014, 2:14 PM, J. Landman Gay wrote: The text is truncated, not simply not displayed: Mystery solved. I was testing in LC 7.0: http://quality.runrev.com/show_bug.cgi?id=13508 -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://

Re: Stripping Returns

2014-11-19 Thread JB
More info that is good to know. Thanks again. John Balgenorth On Nov 19, 2014, at 12:14 PM, J. Landman Gay wrote: > On 11/19/2014, 10:54 AM, dunb...@aol.com wrote: >> The text is truncated, not simply not displayed: >> >> >> >> on mouseUp >>put "1234567890 " into temp >>repeat 1

Re: Stripping Returns

2014-11-19 Thread J. Landman Gay
On 11/19/2014, 10:54 AM, dunb...@aol.com wrote: The text is truncated, not simply not displayed: on mouseUp put "1234567890 " into temp repeat 1 put temp after accum end repeat put accum into fld 1 -- 110,000 chars answer the length of fld 1 end mouseUp You get

Re: Stripping Returns

2014-11-19 Thread JB
ot; into temp >> repeat 1 >> put temp after accum >> end repeat >> put accum into fld 1 -- 110,000 chars >> answer the length of fld 1 >> end mouseUp >> >> You get 65,533. >> >> Not sure where the last two chars went. >> >&

Re: Stripping Returns

2014-11-19 Thread Jerry Jensen
riginal Message- > From: J. Landman Gay > To: How to use LiveCode > Sent: Wed, Nov 19, 2014 11:15 am > Subject: Re: Stripping Returns > > > Reading a file always gives you all the content regardless of the size, up to > memory limits. Displaying a long line of text wi

Re: Stripping Returns

2014-11-19 Thread JB
what you do with that data may hit a wall. >>> >>> >>> Craig Newman >>> >>> >>> >>> -Original Message- >>> From: JB >>> To: How to use LiveCode >>> Sent: Tue, Nov 18, 2014 9:48 pm >>> S

Re: Stripping Returns

2014-11-19 Thread JB
ful hint, I guess. Or learn the hard way, like you did. > That is what I do. At least that method sticks, until I forget it, that is. > > > Craig > > > > -Original Message- > From: JB > To: How to use LiveCode > Sent: Wed, Nov 19, 2014 5:48 am > Sub

Re: Stripping Returns

2014-11-19 Thread dunbarx
two chars went. Craig -Original Message- From: J. Landman Gay To: How to use LiveCode Sent: Wed, Nov 19, 2014 11:15 am Subject: Re: Stripping Returns Reading a file always gives you all the content regardless of the size, up to memory limits. Displaying a long line of text will t

Re: Stripping Returns

2014-11-19 Thread J. Landman Gay
gt; >> -Original Message- >> From: JB >> To: How to use LiveCode >> Sent: Tue, Nov 18, 2014 9:48 pm >> Subject: Stripping Returns >> >> >> A field has a limit on the amount of characters >> you can have on each line. What if I put the

Re: Stripping Returns

2014-11-19 Thread dunbarx
guess. Or learn the hard way, like you did. That is what I do. At least that method sticks, until I forget it, that is. Craig -Original Message- From: JB To: How to use LiveCode Sent: Wed, Nov 19, 2014 5:48 am Subject: Re: Stripping Returns Thank you. The logic is simple enough

Re: Stripping Returns

2014-11-19 Thread JB
urse, but what you do > with that data may hit a wall. > > > Craig Newman > > > > -Original Message- > From: JB > To: How to use LiveCode > Sent: Tue, Nov 18, 2014 9:48 pm > Subject: Stripping Returns > > > A field has a limit on the am

Re: Stripping Returns

2014-11-18 Thread dunbarx
, but what you do with that data may hit a wall. Craig Newman -Original Message- From: JB To: How to use LiveCode Sent: Tue, Nov 18, 2014 9:48 pm Subject: Stripping Returns A field has a limit on the amount of characters you can have on each line. What if I put the text of a field in

Stripping Returns

2014-11-18 Thread JB
A field has a limit on the amount of characters you can have on each line. What if I put the text of a field in a variable and it has 500,000 characters. Then I strip all of the returns that are in the field. Does that leave only one line with 500,000 characters? That exceeds the amount of char