Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.
Open Insight Copy From Edit Box Glitch
If you have an edit box with text in it you can copy the text in two ways:
1. CTRL-C
2. Context Menu
When I copy via the context menu, it works fine. But when I copy via CTRL-C, the new lines in the text are copied as this character û, which I am pretty sure is the @fm character (or one of the other ones).
Is this normal, or is there something wrong I am doing?
I guess to fix I need to capture the copy event and then swap the û with \r\n...but this shouldn't even be happening to begin with, right?
1. CTRL-C
2. Context Menu
When I copy via the context menu, it works fine. But when I copy via CTRL-C, the new lines in the text are copied as this character û, which I am pretty sure is the @fm character (or one of the other ones).
Is this normal, or is there something wrong I am doing?
I guess to fix I need to capture the copy event and then swap the û with \r\n...but this shouldn't even be happening to begin with, right?
Comments
Are you handling Ctrl+C yourself? If so, how are you doing this?
value = get_property(focusField, 'DEFPROP') selection = get_property(focusField, 'SELECTION') iF selection<2> > 0 THEN value = value[selection<1>, selection<2>] end oryxlib_copy_to_clipboard(value)
oryxlib_copy_to_clipboard
--------------------------------------
if value then convert @vm to ',' in value swap @fm with crlf$ in value set_property('CLIPBOARD', 'TEXT', value) // srp_set_clipboard_text end
So I need to make it swap @tm with \r\n, i think. But I'd rather not do anything. I would have assumed that ctrl-c would just work without us having to do anything. is this not true?
@Josh, you could risk removing the logic (risk if it's part of promoted events, not so much if it's a direct call for that function only) or you could probably get the result you're looking for by adding
swap @tm with crlf$ in value
swap @tm with crlf$ in value
thanks