Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Copy text on About window #6332

Closed
luisdev opened this issue Nov 28, 2023 · 22 comments
Closed

Copy text on About window #6332

luisdev opened this issue Nov 28, 2023 · 22 comments
Assignees
Milestone

Comments

@luisdev
Copy link

luisdev commented Nov 28, 2023

When you click the About option on the Help menu MMX displays the About window with the About tab selected. All the MMX version details are displayed. You cannot copy any of the text that is displayed and I've often wanted to copy some of the data when writing a forum post or posting something here on github. You can SELECT text on this About tab, but you can't COPY it to the clipboard.

Can you add the right-click option to COPY text that you have selected on this About tab?


• Version: 1.7.0-Beta.1 64-bit
• Built: Nov 14 2023 00:27:34
• db 19 (aes128cbc)
• git 300316a (2023-11-14)

Libs:
• wxWidgets 3.2.3 (wxMSW 10.0)
• wxSQLite3 4.9.1 (SQLite 3.40.0)
• RapidJSON 1.1.0
• Lua 5.3.5
• libcurl/7.82.0-DEV Schannel
• gettext 0.19.8.1
• apexcharts.js

Built with:
• CMake 3.16.2
• MSBuild 15.9.21.664
• MSVS15.0
• MSVSC 19.16.27035.0
• Windows SDK 10.0.14393.0

OS:
• Windows 10 (build 19045), 64-bit edition
• System Locale:
• User Interface Language: en_GB.windows-1252
• 1920x1200 32-bit 96x96ppi
@renato-mmex
Copy link

you can select the text and copy it to the clipboard with ctrl+c.

@luisdev
Copy link
Author

luisdev commented Nov 28, 2023

Ok, I tried that on my Windows 10 Pro 22H2 build 19045.3693 pc, but it's tricky! And maybe buggy?

Try this:

  1. Click Help / About to open the About window.
  2. Select the first line:
    • Version: 1.7.0-Beta.1 64-bit
  3. Press ctrl+c.
  4. Open Notepad,exe.
  5. Right click in Notepad and select Paste or press ctrl+v.
  6. You'll see the correct text pasted in notepad:
    • Version: 1.7.0-Beta.1 64-bit
  7. Go back to the MMX About window.
  8. Select the next line:
    • Built on: Nov 14 2023 00:27:34
  9. Press ctrl+c.
  10. Go back to Notepad,exe and press ctrl+v to paste the new text you selected and copied.
  11. It STILL pastes the origional text you selected
    • Version: 1.7.0-Beta.1 64-bit
    instead of the new text you selected:
    • Built on: Nov 14 2023 00:27:34
    It should have pasted the new selected line into Notepad:
    • Built on: Nov 14 2023 00:27:34

Now try this:

  1. Go back to the MMX About window.
  2. Select the next line:
    • Database version: 19 (aes128cbc)
  3. Press ctrl+c MORE THAN ONCE in quick succession.
  4. Go back to Notepad and press ctrl+v:
  5. Now it pastes the correct text that you selected:
    • Database version: 19 (aes128cbc)
  6. Repeat the above (select text, then press ctrl+c more than once)
  7. Press ctrl+v in Notepad.
  8. The correct text that you selected is pasted into Notepad.

So, it seems like you have to press the ctrl+c keys multiple times in quick succession for the copy from the About window to work. That's not very intuitive.

Can you reproduce this?
Is this a bug, or by design?
Is this how Copy / Paste in wxWidgets works?

@renato-mmex
Copy link

Place the cursor on the first character, hold down the left mouse button and drag the cursor down to the last desired character, so that the desired text is highlighted in blue, then copy it to the clipboard with ctrl+c.

Sorry, these are basic Windows, Editor .... functions : https://edu.gcfglobal.org/en/windowsbasics/keyboard-shortcuts-in-windows/1/

@luisdev
Copy link
Author

luisdev commented Nov 28, 2023

Thanks Renato. I am quite familiar with how the Windows copy and paste functionality works. And it's working on all applications on my computer, except on this About screen in MMX, as per my description.

@whalley
Copy link
Member

whalley commented Nov 28, 2023

Seems fine for me on MacOS and Win11.

@rmelillo76
Copy link

rmelillo76 commented Nov 28, 2023

I was very surprised, but I can reproduce this as well. I'm not sure why the Ctrl+C sequence is not consistently copying the selected text. Are we using a web browser control or a rich text editor to display the formatted contents ?

@whalley
Copy link
Member

whalley commented Nov 28, 2023

I was very surprised, but I can reproduce this as well. I'm not sure why the Ctrl+C sequence is not consistently copying the selected text. Are we using a web browser control or a rich text editor to display the formatted contents ?

It's a wxHtmlWindow.

@rmelillo76
Copy link

rmelillo76 commented Nov 29, 2023

Thanks @whalley

I did some basic testing and found on Windows 10 that the screens using wxHtmlWindow that consistently copy to the clipboard using CTRL+C are the ones that also have the right click context menu enabled:

  1. Help > Help (F1)
  2. Help > Report a Bug
  3. GRM Main Help Page (Click on General Reports Manager)
  4. GRM Output Tab
  5. All GRM Reports
  6. All Standard Reports
  7. Transaction Report

On the contrary, screens that do not have the right click context menu as was reported here do not seem to register CTRL+C consistently, or at all, EXCEPT the Dashboard/Home Page. For whatever reason that works 100% of the time for me:

  1. Help > About (All tabs)
  2. Help > View Diagnostics
  3. Theme Manager

Not sure how important this is but thought I'd let you folks know my findings.

@whalley
Copy link
Member

whalley commented Nov 29, 2023

Apologies I was just using CTRL+C to cut the detail, never even looked at right-click! Agreed a right-click menu does not exist. But I can;t see any issues with CTRL+C.

Not sure this is really something we should expend energy on adding right-click menu, the ability to copy is there.

@rmelillo76 The pages that you mention that have right click menus are based on wxWebView controls and not wxHtmlWindow and are used for more expansive, web-browser like, pages.

@rmelillo76
Copy link

@rmelillo76 The pages that you mention that have right click menus are based on wxWebView controls and not wxHtmlWindow and are used for more expansive, web-browser like, pages.

Thanks, that helps clarify. I guess there are some quirks (and possibly only on Windows) with how CTRL+C is handled in the wxWebView control. And quite possibly outside of our control.

@renato-mmex
Copy link

There are many windows in MS Windows that cannot be selected and copied (e.g. error messages). Microsoft has simply not brought its old windows and functions up to date over the years.

@rmelillo76
Copy link

@renato-mmex

There are many windows in MS Windows that cannot be selected and copied (e.g. error messages). Microsoft has simply not brought its old windows and functions up to date over the years.

While this is true, many Windows users don't know that you can copy info from dialogs using CTRL+C. I know I was surprised when I found this somewhat obscure feature many years ago:

https://winaero.com/copy-text-message-box-windows-10/

A couple examples:

image

Pressing CTRL+C places the following into the clipboard:

[Window Title]
MMEX Options

[Content]
General page has been saved.

[OK]

And:

image

[Window Title]
Confirm Transaction Deletion

[Main Instruction]
Do you really want to delete the selected transaction?

[Content]
Deleted transactions will be temporarily stored and can be restored from the Deleted Transactions view.

[Yes] [No]

@ovari
Copy link
Contributor

ovari commented Nov 30, 2023

Can you add the right-click option to COPY text that you have selected on this About tab?

Should a right-click option to Select All also be added?

whalley added a commit to whalley/moneymanagerex that referenced this issue Nov 30, 2023
@whalley
Copy link
Member

whalley commented Nov 30, 2023

This should resolve the 'issue'

CleanShot 2023-11-30 at 22 36 21

@whalley whalley self-assigned this Nov 30, 2023
@whalley whalley added this to the v1.7.0 milestone Nov 30, 2023
whalley added a commit that referenced this issue Nov 30, 2023
fix(#6332): add copy to clipboard
@ovari
Copy link
Contributor

ovari commented Dec 1, 2023

This should resolve the 'issue'

Can there please be a keyboard shortcut? For example, the C in Copy?

&Copy all text to clipboard or _Copy all text to clipboard

What do you think?

Thank you

@ovari
Copy link
Contributor

ovari commented Dec 1, 2023

While this is true, many Windows users don't know that you can copy info from dialogs using CTRL+C. I know I was surprised when I found this somewhat obscure feature many years ago:

Unfortunately, this does not seem to be the case with GNU/Linux.

@ovari
Copy link
Contributor

ovari commented Dec 1, 2023

image

The icon seems to be an Open icon. Would it be better to change the icon to a Copy icon?

The keyboard shortcut Ctrl+O does not work. Should the keyboard shortcut be changed to Ctrl+C?

Thank you

Money Manager Ex
• Version: 1.7.0-Beta.1 64-bit
• Built on: Dec 1 2023 03:16:22
• Database version: 19 (aes128cbc)
• Git commit: df1680403 (2023-11-30)
• Git branch: master
MMEX is using the following support products:
• wxWidgets 3.2.4 (wxGTK 3.24)
• wxSQLite3 4.9.1 (SQLite 3.40.0)
• RapidJSON 1.1.0
• Lua 5.3.5
• libcurl/8.4.0-DEV OpenSSL/3.1.4 zlib/1.3 nghttp2/1.56.0
• gettext 0.22
• apexcharts.js
Built with:
• CMake 3.27.7
• GNU Make 4.4.1
• GCC 13.2.0
Running on:
• GNOME.45 (Flatpak runtime)
• GNOME 45 (Flatpak runtime) ""
• Linux 5.15.0-89-generic x86_64
• X-Cinnamon (X11)
• System Locale: en_AU.UTF-8
• User Interface Language: en_US.UTF-8
• 1440x810 24-bit 96x96ppi

whalley added a commit to whalley/moneymanagerex that referenced this issue Dec 1, 2023
@whalley
Copy link
Member

whalley commented Dec 1, 2023

The icon seems to be an Open icon. Would it be better to change the icon to a Copy icon?
The keyboard shortcut Ctrl+O does not work. Should the keyboard shortcut be changed to Ctrl+C?

Think this is due to poor selection of the menu ID. Hopefully fixed now.

Not planning to have a keyboard accelerator for this. It was added to cover the case mentioned above when users are not familiar with keybaord shortcuts - so a simple right-click menu was added.

Think we have done enough to address the original concern.

whalley added a commit that referenced this issue Dec 1, 2023
@luisdev
Copy link
Author

luisdev commented Dec 1, 2023

Think we have done enough to address the original concern.

It's perfect! I will test.
Thank uou.

@rmelillo76
Copy link

Can there please be a keyboard shortcut? For example, the C in Copy?

&Copy all text to clipboard or _Copy all text to clipboard

What do you think?

Thank you

What's the point - Who is going to use their mouse to perform a right click then want to switch to using the keyboard and expect a keyboard accelerator? It just seems unnecessary and I think Mark is done enough to help with this request.

@luisdev
Copy link
Author

luisdev commented Dec 1, 2023

The implemented solution is great. Now you can do both - copy selected text and copy all text! :-)
Thank you.

@whalley whalley closed this as completed Dec 1, 2023
@ovari
Copy link
Contributor

ovari commented Dec 1, 2023

Thank you for your implementation. Do you know when the string will be available for translation on Crowdin? Thank you once again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants