Text editing improvements (addressing various gotchas and bugs)

One of my common frustrations when working in Pinegrow is that text handling operations like selecting, editing, copying and pasting do not behave in a predictable way. When I say ‘predictable’, I mean, like a native text-based app. (I realise that Pinegrow is built using Web technologies and is not a native app, but it should still mimic standard OS behaviour to be considered a well-behaved app.)

I’m a Mac user, but these principles should apply on Windows too.

Text selection:

  1. Double click a word to select it. Shift-clicking on another word should then select all the words up to and including that word. (In Pinegrow, Shift-click does not add anything to the selection.)

  2. By clicking and dragging, you can select a range of text, even across multiple paragraphs. However, if you have entered ‘inline text editing mode’ by double-clicking on a word, Pinegrow will not let you select text beyond the end of the the first paragraph. (A minor bug.)

  3. With ‘inline text editing’ turned off, you can Shift-click to select multiple block-level elements (like paragraphs), but this is not mirrored in the code, which only shows a selection around the most recently clicked element. This inconsistency creates confusion about what will happen if you delete or replace the selection.

  4. There are many other instances where the inline text selection simply isn’t reflected in the code at all. I find that I have to turn inline text editing off and back on before it will start showing the selection in code again.

Copying and pasting:

  1. If you cut or copy one or more block level elements (say a paragraph), then select another block level element and try to paste, the expected behaviour is for the copied/pasted element to replace the selected element. However, Pinegrow retains the selected element and pastes everything after it.

  2. The situation is even worse if you have multiple items selected before pasting. In this case, you end up with duplicate copies of the pasted elements—one after each of the selected elements! (This is a major bug in my opinion.)

  3. If you copy styled text (either from Pinegrow or another app), there is no option in Pinegrow to paste the raw text, stripped of its styling. (Most native Mac apps have a command called ‘Paste and Match Style’ which does this.)

Undo and redo:

  1. I can’t reliably reproduce this, but there have been occasions where something unexpected happens and I cannot undo it. It happened once even while I was testing just now, but I’m not sure how to reproduce the steps that caused it.

I totally agree. So much time is spent just editing text that this needs to be improved. Often i copy & paste from other editors. I’d like an option to paste only raw text ignoring any formatting that comes with it.

I would love to see the text editor with a markdown mode (like the PUG mode) or a markdown text-file import integrated in Pinegrow. This can also address a lot of the issues mentioned above.

Thanks Paul, I agree with the option to paste raw text without formatting. I’ve added it to the above list (#7).

Martin, I agree that Markdown support would be useful. I tend to write in Markdown myself, then export to HTML before copying and pasting into Pinegrow, so this feature could save me some time.

But this is really a separate feature request. Basic text handling operations should be consistent and predictable no matter what kind of editing mode you’re in.

1 Like

Well, since we are on the subject… Yes, I guess PUG is nice.
However… being part of the awkward squad… I was quite happily starting to use Emmet (Old Zen Coding)


.another reason I rather fancied sublime text 3 support…still. (Which I use Emmet with via a plugin)

Just a ‘!’ followed by Tab for the entire html 5 doctype decleration.
and lots of nice nested lists sort of speedy writing stuff.

I am enjoying Visual Studio Code using/learning Emmet and having full access to modify anything, and with Gulp watch it recompiles changes and redisplays.

To make everything more real-time I have it in ‘save auto’ mode so I never need to press Ctrl-S.