PDA

View Full Version : Copying and Pasting Text Without Context



Minty23185Fresh
March 17th, 2023, 18:34
I migrate a lot of Adventurers League PDFs to Fantasy Grounds. I use a "shorthand" formatting so that I have the important details without all the fluff. It helps me run more time efficient sessions.

I've notice that copying, cutting and pasting text maintains the paragraph context. And I have found, that in general, for me, this is a major pain-in-butt.

Copying a little snippet from, say a Chat box paragraph type, into the middle of say a heading or a link and having the editor break the heading or link into two with a couple words of chat in the middle is a real nuisance.

The FG wiki, Basic Guides/Basic Actions Formatted Text page (https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/996640055/Basic+Actions#Formatted-Text-Fields), confirms this is the appropriate behavior.

Just by chance, is there a keyboard shortcut, or some such thing that would strip (or copy without) the context into the copy/paste buffer?

Maybe even an extension?

True, I admit I'm persnickety, but it's hard for me to believe others don't find this behavior a bit trying.

(I had hopes for the Windows, strip format, Ctrl-Shift-V, paste, but it doesn't work.)

So far, the quickest method I've found is pasting into the text entry field of the tabletop Chat Box, then dragging that to the intended destination. Cumbersome to say the least.

Example screenshot:
56740

Zacchaeus
March 17th, 2023, 20:20
Well, it used to be the case that formatting was stripped out when copy/pasting but now it is retained. I know of no way to overcome this (and I find it super duper useful :D )

Minty23185Fresh
March 17th, 2023, 20:30
Well, it used to be the case that formatting was stripped out when copy/pasting but now it is retained. I know of no way to overcome this (and I find it super duper useful :D )
I have to agree that at times it can be very useful, for instance bolded, italicized, and underlined text, and just copying the link or chat message from one story page another. so the extra key methodology (ctrl-shift-V) would be the most useful way of defeating it.

[EDIT] But I just found out bold, italics and underlining are not maintained. Aargh!!

LordEntrails
March 17th, 2023, 21:23
CTRL-J
Removes line breaks.

CTRL-1 sets to normal paragraph.

So, CTRL-A then CTRL-J

But you can also paste to NPP first. That's what I do to clean it up before pasting into FG. But, it's an extra step.

Minty23185Fresh
March 17th, 2023, 21:58
CTRL-J
Removes line breaks.

CTRL-1 sets to normal paragraph.

So, CTRL-A then CTRL-J

But you can also paste to NPP first. That's what I do to clean it up before pasting into FG. But, it's an extra step.

Sorry, LordEntrails but I'm talking about copy/paste, all within FG.
I have an extension that I wrote/use that strips out the extra linefeeds/carriages returns, takes care of ligature errors and a host of other stuff for the PDF --> FG part of the migrate.

Once, pasted into FG, if I copy snippets of text from one Story window to another, any formatting that has been done, carries from one Story dialog to another. And even within a window.

Another example might help.
56744

Minty23185Fresh
March 17th, 2023, 22:07
Meaning that if I put my cursor at the end of Faction: on each link and hit "delete" or Ctrl-J I get this
And every link points to the Emerald Enclave, irregardless of the label.

56745

Which is far from helpful! To fix it I need to Ctrl-1 each link, then drag the correct source link on top of it.

Minty23185Fresh
March 17th, 2023, 22:17
BTW, I can't escape the formatting by typing "FACTION:" somewhere else in the Story and then copy/pasting it, because it will bring "body" format along and I get this:
56747

Laerun
March 17th, 2023, 22:32
BTW, I can't escape the formatting by typing "FACTION:" somewhere else in the Story and then copy/pasting it, because it will bring "body" format along and I get this:
56747

I have experienced this behavior at times too. It is like the initial formatting grabs or retains the URL data in addition to just the text and does not shed or release the URL context once it's associated with a line that contains link data.

Minty23185Fresh
March 17th, 2023, 22:57
Okay. Talking this through with you guys has helped me come up with a solution for myself.

The PDF import extension that I have does a lot of things to the Clipboard object, like using Chat slash-commands and hotkeys to poke things like bullet points or carriage-linefeeds into the Clipboard, which I then Ctrl-V into a Chat box text. I'll just add another slash-command that copies the Clipboard text to a lua variable, which will clear the formatting, then copy it back into the Clipboard. When I Ctrl-V it into a Story it will be pure unformatted text.

It's an extra step, but for me the most palatable. Thanks for listening to my rants... You guys helped me see the light. :o

LordEntrails
March 17th, 2023, 23:21
Glad you got it sorted. Yea, I wasn't very coherent in my reply :) In short I think adding the CTRL-1 to your script should help you out. But I think you have it figured now?

Minty23185Fresh
March 17th, 2023, 23:42
I have experienced this behavior at times too. It is like the initial formatting grabs or retains the URL data in addition to just the text and does not shed or release the URL context once it's associated with a line that contains link data.
Exactly. Links are the most “retentive”, it seems. I’ve found, that to get it to clear that link formatting plus clear the link data, just retaining the label, I use a Ctrl-1 to format the label to body text. And if I know I’m just putting a different data link there with the retained text (label) I’ll do a quick Ctrl-5, to create a “empty” link.

It acts like a placeholder. Sometimes I misplace those dang links, drag-dropping them in just the slightly wrong place and I’m all fouled up. Doing the Ctrl-5 gives me a target! ;)

Moon Wizard
March 29th, 2023, 01:39
A Shift-Control-V shortcut key option has been added to Paste without formatting in v4.3.7.

Regards,
JPG

Minty23185Fresh
March 29th, 2023, 02:37
A Shift-Control-V shortcut key option has been added to Paste without formatting in v4.3.7.

OM… Thank you so much Moon Wizard!!