Skip to content

inconsistent behavior when copying with context menu vs ctrl + c from markdown preview #12339

@bwat47

Description

@bwat47

Operating system

Windows

Joplin version

3.3.12

Desktop version info

Joplin 3.3.12 (prod, win32)

Device: win32, Intel(R) Core(TM) i7-10750H CPU @ 2.60GHz
Client ID: acf44d67875e4c478d29d7d4c738fc72
Sync Version: 3
Profile Version: 47
Keychain Supported: Yes
Alternative instance ID: -

Revision: 4d790b6

Backup: 1.4.3
Joplin Calendar: 1.2.0
Journal: 2.0.0
Note Tabs: 1.4.0
Rich Markdown: 0.16.0
Templates: 2.4.0

Current behaviour

  1. Create a note with some bold text
  2. In markdown editor, switch to preview mode
  3. Highlight bold text from markdown preview
  4. Copy text with ctrl + c
  5. Paste into an app that accepts HTML formatting (e.g. Gmail, Outlook, Word)
  6. You'll see that this pastes bold formatting as expected
  7. Go back to markdown preview and copy the same text with Right click | Copy
  8. Paste into the same app and you'll see that it only pastes plaintext without formatting

Expected behaviour

A. Behavior should be consistent between copying with ctrl + c and context menu

B. context menu copy should behave the same as the ctrl + c copy (copying text with formatting, since we are copying from the rendered HTML preview).

NOTE: When copying from the markdown preview with ctrl + c, it copies both text/plain and text/html, so it plays nicely whether you're pasting into an app that accepts html formatting, or an app that only accepts plaintext:

Image|500

So I'm not sure there needs to be an option that only populates the clipboard text/plain category (the only reason I can think of is to allow pasting as plaintext into apps that do support pasting rich text, but don't support the common ctrl + shift + v keyboard shortcut to force pasting text/plain instead of text/html). If this is desired, I feel like it would make more sense if it was a separate context menu option/separate keyboard shortcut (e.g. "Copy as plaintext only").

NOTE: Related rich text editor issue where ctrl + c and right click | copy have different behaviors: #12336

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIt's a bugstaleAn issue that hasn't been active for a while...

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions