KeyboardKitPro icon indicating copy to clipboard operation
KeyboardKitPro copied to clipboard

Using selectedText to capture the a selected text in a document without truncating it

Open anonys opened this issue 1 year ago • 3 comments

is there a way to surpass the limitation of selectedText() when the text selection is beyond 2 lines.

anonys avatar Sep 15 '24 22:09 anonys

Hi @anonys

Apple's APIs are really restricted when it comes to accessing text from the proxy.

I guess the full document reader capability is not what you're after, but only the selected text?

danielsaidi avatar Sep 16 '24 06:09 danielsaidi

Hey @danielsaidi Yes correct, I am using full document reader when I want to access the whole text but in certain situations I need to get the selected text only - and sometimes it's beyond 2 lines.

anonys avatar Sep 16 '24 10:09 anonys

If the range information can be used, it should be possible, but I'm sure it requires the same kind of underlying operations as the full document reader. I'll keep this open.

danielsaidi avatar Sep 16 '24 11:09 danielsaidi

I have moved this to the main repository.

danielsaidi avatar Aug 30 '25 08:08 danielsaidi