Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » ide: Copy position, Goto clipboard position
ide: Copy position, Goto clipboard position [message #55314] Thu, 29 October 2020 10:03 Go to next message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
I have got an simple yet useful idea to be used usually when chatting about code (e.g. here in the forum, or with colleague etc...)

The new TheIDE

Copy position Alt+U

function simply copies the current filename (in host independent form) and line onto clipboard. The idea is that you can then simple paste it to the message like this:

ide/idetool.cpp 108

Now the reader of your message can copy it to clipboard and then in TheIDE invoke

Goto clipboard position Alt+Y

and see the referenced code easily.

Mirek
Re: ide: Copy position, Goto clipboard position [message #55317 is a reply to message #55314] Thu, 29 October 2020 14:28 Go to previous messageGo to next message
mr_ped is currently offline  mr_ped
Messages: 825
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
very nice! Smile (now I just need to remember it exists)
Re: ide: Copy position, Goto clipboard position [message #55318 is a reply to message #55314] Thu, 29 October 2020 20:05 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1378
Registered: December 2006
Ultimate Contributor
mirek wrote on Thu, 29 October 2020 05:03

ide/idetool.cpp 108

IMHO, it is usually has format
ide/idetool.cpp:108


Regards,
Novo
Re: ide: Copy position, Goto clipboard position [message #55319 is a reply to message #55318] Thu, 29 October 2020 20:06 Go to previous messageGo to next message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
Novo wrote on Thu, 29 October 2020 20:05
mirek wrote on Thu, 29 October 2020 05:03

ide/idetool.cpp 108

IMHO, it is usually has format
ide/idetool.cpp:108


I was undecided. Should I change it?

Mirek
Re: ide: Copy position, Goto clipboard position [message #55320 is a reply to message #55319] Thu, 29 October 2020 20:15 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1378
Registered: December 2006
Ultimate Contributor
mirek wrote on Thu, 29 October 2020 15:06
Novo wrote on Thu, 29 October 2020 20:05
mirek wrote on Thu, 29 October 2020 05:03

ide/idetool.cpp 108

IMHO, it is usually has format
ide/idetool.cpp:108


I was undecided. Should I change it?

Mirek

IMHO, yes. GCC uses this format, VIM QuickFix list supports this format.


Regards,
Novo
Re: ide: Copy position, Goto clipboard position [message #55324 is a reply to message #55320] Fri, 30 October 2020 11:14 Go to previous messageGo to next message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
So be it, it is now ide/idetool.cpp:108

[Updated on: Fri, 30 October 2020 11:14]

Report message to a moderator

Re: ide: Copy position, Goto clipboard position [message #55709 is a reply to message #55324] Wed, 02 December 2020 09:28 Go to previous messageGo to next message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
I have extended the accepted syntax for "Go to clipboard position", so that it basically accepts error messages pasted in the forum too, like:

c:\upp\upp.src\uppsrc\ide\idetool.cpp (108): Something
Re: ide: Copy position, Goto clipboard position [message #55766 is a reply to message #55709] Fri, 11 December 2020 14:12 Go to previous messageGo to next message
Xemuth is currently offline  Xemuth
Messages: 387
Registered: August 2018
Location: France
Senior Member
Hello, I just posted a mesage using this feature on forum, it's very convenient !
However, when jumping to a file which is not part of a package (let's say c:\upp\upp\bin\clang\include\sal.h) and try to copy position, the copy position don't work (my clipboard remain the same as before the copy position).
It would be good to copy filename and position when TheIDE don't know from what package this file come from
Re: ide: Copy position, Goto clipboard position [message #55769 is a reply to message #55766] Fri, 11 December 2020 15:39 Go to previous messageGo to next message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
Xemuth wrote on Fri, 11 December 2020 14:12
Hello, I just posted a mesage using this feature on forum, it's very convenient !
However, when jumping to a file which is not part of a package (let's say c:\upp\upp\bin\clang\include\sal.h) and try to copy position, the copy position don't work (my clipboard remain the same as before the copy position).
It would be good to copy filename and position when TheIDE don't know from what package this file come from


I can do that, but it will just work with Copy position, not Alt+Y. Do we want to go there?

Mirek
Re: ide: Copy position, Goto clipboard position [message #55774 is a reply to message #55769] Fri, 11 December 2020 16:55 Go to previous messageGo to next message
Xemuth is currently offline  Xemuth
Messages: 387
Registered: August 2018
Location: France
Senior Member
IMO I think it's better to have file:line when file is not part of package than nothing when copy position. I can add this feature to TheIDE and share a patch file if you lack of time Very Happy

Also, what if, if no package is present in clipboard, TheIDE look for all includes directories of each build method to find the file present in clipboard ? maybe it would be to heavy

[Updated on: Fri, 11 December 2020 16:58]

Report message to a moderator

Re: ide: Copy position, Goto clipboard position [message #55776 is a reply to message #55774] Fri, 11 December 2020 17:31 Go to previous message
mirek is currently online  mirek
Messages: 14164
Registered: November 2005
Ultimate Member
OK, done
Previous Topic: GridCtrl selection UI refactored
Next Topic: ide: New assembly/nest rule
Goto Forum:
  


Current Time: Sat Dec 14 14:46:12 CET 2024

Total time taken to generate the page: 0.03714 seconds