Forum > Debugger
FpDebug feature request on Copy
(1/1)
440bx:
Hello,
Please refer to the attachment.
When copying a value from the watches window, it seems there is no option that will copy an address in "raw" form, i.e., without a "$" and without any additional information that may be shown due to formatting.
It would often be useful to have the option of copying the raw address, i.e., without any ornaments into the clipboard so it can be used by external, non-Pascal based, tools.
In the attachment, copying AI_ADDRESS into the clipboard yields the value shown in the first "Jump to address" box. Ideally, there would be an option (which is what's being requested in this post) to cause the copy of AI_ADDRESS in the clipboard to be what is shown in the second "Jump to address" box.
Thank you for reading.
Martin_fr:
Please report as a feature request.
It is easy to change (but to be added to the IDE, needs an option)
ide\packages\idedebugger\watchesdlg.pp
LINE 1686
inside TDbgTreeViewWatchValueMgr.GetFieldAsText
case ....
vdfDataAddress: begin
Just replace the '$' + IntToHex(
and the "nil"
That will affect display too.
Or in
TWatchesDlg.actCopyAddrExecute
de-parse the $ string.
Actually, when you make the feature request, should it be
- an extra menu entry
- maybe if some of those many "copy..." entries are grouped into a sub menu...
but that means more clicks to reach them.
- maybe context menu with modifier key?
- an option to toggle the existing entry
- ?
440bx:
It's great to have the code that needs to be changed. I can change the version of Lazarus I'm using which spares me from having to configure a new/different version. :) Thank you very much for that Martin.
--- Quote from: Martin_fr on January 31, 2025, 10:21:53 am ---Please report as a feature request.
--- End quote ---
Will do after posting this.
--- Quote from: Martin_fr on January 31, 2025, 10:21:53 am ---Actually, when you make the feature request, should it be
- an extra menu entry
- maybe if some of those many "copy..." entries are grouped into a sub menu...
but that means more clicks to reach them.
- maybe context menu with modifier key?
- an option to toggle the existing entry
- ?
--- End quote ---
The thought of having the "copy" entries grouped into a submenu is unappealing because of the extra clicks needed and the fact that the options are not immediately visible.
I would prefer an additional entry or the option to toggle the operation of an existing entry, the "Copy RAW value" seems like a good candidate to me because I interpret "RAW" as being "unadorned".
Again, thank you.
ETA:
feature request: 41385
link: https://gitlab.com/freepascal.org/lazarus/lazarus/-/issues/41385
Martin_fr:
Maybe group some items into a submenu?
Like "Copy all", "Copy raw value", "Copy Data Address (raw)"
440bx:
--- Quote from: Martin_fr on January 31, 2025, 12:08:47 pm ---Maybe group some items into a submenu?
Like "Copy all", "Copy raw value", "Copy Data Address (raw)"
--- End quote ---
Here is a thought...
Have all the "Copy" options grouped in a submenu _but_ any option that is eventually chosen from the submenu is, as a result of having been chosen, "promoted" to the higher level menu. That way, the option(s) that are commonly used become available without having to constantly go into the submenu to get them.
How does that sound to you ?
One thought I really like is to allow up to 3 (or some other number) lines in the main popup menu for the common "Copy" options. That way, the 3 most commonly (and/or recently) used copy options would be available without any additional clicks. if a different option than the top 3 is later chosen from the submenu then that option would automatically replace the least used of the 3 primary options. Basically, a dynamic list that combines "most used" with "most recently used".
All that said, I'll be perfectly happy with just having one additional line in the current popup menu. In that case, I'd like to have the option closer to the top of the list than the bottom.
Navigation
[0] Message Index