Remember the current procedures positions on the right panel

Working on new editor enhancements?
User avatar
marcoagpinto
Addict
Addict
Posts: 939
Joined: Sun Mar 10, 2013 3:01 pm
Location: Portugal
Contact:

Remember the current procedures positions on the right panel

Post by marcoagpinto »

Hello!

This is an important feature request.

While I am working on my projects, I have them separated in different include files which I have more than one open in the PB IDE.

However, every time I click on a different tab in the IDE, the position of the procedures in the panel on the right is reset to the top.

Can't a variable be used for each tab to store which procedure is at the top of the list, so that positions never change when we click around the tabs?

Thanks!
BarryG
Addict
Addict
Posts: 3292
Joined: Thu Apr 18, 2019 8:17 am

Re: Remember the current procedures positions on the right p

Post by BarryG »

+1
davido
Addict
Addict
Posts: 1890
Joined: Fri Nov 09, 2012 11:04 pm
Location: Uttoxeter, UK

Re: Remember the current procedures positions on the right p

Post by davido »

+1
DE AA EB
User avatar
Tenaja
Addict
Addict
Posts: 1948
Joined: Tue Nov 09, 2010 10:15 pm

Re: Remember the current procedures positions on the right p

Post by Tenaja »

+1!!!

This is extremely annoying on large projects, and I definitely hope it's implemented.
User avatar
Shardik
Addict
Addict
Posts: 1988
Joined: Thu Apr 21, 2005 2:38 pm
Location: Germany

Re: Remember the current procedures positions on the right p

Post by Shardik »

If an IDE feature is so important for you, why don't you implement it yourself? The PureBasic IDE is open source since December 2019 and is awaiting your pull requests on GitHub. Please don't wait for others to do the work for you - please try to do it yourself...
BarryG
Addict
Addict
Posts: 3292
Joined: Thu Apr 18, 2019 8:17 am

Re: Remember the current procedures positions on the right p

Post by BarryG »

Love to do that, but have no idea how GitHub works. Maybe a tutorial on making an addition to the IDE is needed?
User avatar
marcoagpinto
Addict
Addict
Posts: 939
Joined: Sun Mar 10, 2013 3:01 pm
Location: Portugal
Contact:

Re: Remember the current procedures positions on the right p

Post by marcoagpinto »

I, too, don't know how to submit patches to GitHub.

All I do in the open-source projects is to commit the full files to GitHub.
User avatar
kenmo
Addict
Addict
Posts: 1967
Joined: Tue Dec 23, 2003 3:54 am

Re: Remember the current procedures positions on the right p

Post by kenmo »

+1

This is the kind of small UI improvement I would be happy to implement and submit :)

I haven't tried yet, but I think the hard part is needing cross-platform functions to get/set the scroll state of a ListViewGadget.


PS. The PB IDE is a great excuse to practice Git and GitHub! I've submitted patches that are just a few lines of code.
User avatar
kenmo
Addict
Addict
Posts: 1967
Joined: Tue Dec 23, 2003 3:54 am

Re: Remember the current procedures positions on the right panel

Post by kenmo »

1.5 year later...

I have a patch on GitHub that adds this feature to the IDE, but it's Windows only (uses API to get/set listview position)
https://github.com/fantaisie-software/p ... oc-browser

If you know how to build the IDE, you can try it yourself. Or if you trust me, I can upload a Windows IDE executable with the change.

Since this is a Windows-only solution it's unlikely to be accepted into the official IDE, unless other people can implement it for Mac and Linux.
BarryG
Addict
Addict
Posts: 3292
Joined: Thu Apr 18, 2019 8:17 am

Re: Remember the current procedures positions on the right panel

Post by BarryG »

kenmo wrote: Sun Aug 28, 2022 7:46 pmSince this is a Windows-only solution it's unlikely to be accepted into the official IDE, unless other people can implement it for Mac and Linux.
Can't it just be wrapped in "CompilerIf/CompilerEndIf" and be a feature that works on Windows? And stay as it currently is on Linux/Mac.
User avatar
kenmo
Addict
Addict
Posts: 1967
Joined: Tue Dec 23, 2003 3:54 am

Re: Remember the current procedures positions on the right panel

Post by kenmo »

Yes of course it is currently wrapped in a CompilerIf and has no effect on Mac/Linux.

But in my experience, features are not officially merged unless they are implemented for all OS, for example this one from last summer:
https://github.com/fantaisie-software/p ... c/pull/167
"I really don't like features that work on only some OS. It will just look like a bug to users who use PB on more than one platform when things that they are used to from one platform simply don't work on another."
highend
Enthusiast
Enthusiast
Posts: 123
Joined: Tue Jun 17, 2014 4:49 pm

Re: Remember the current procedures positions on the right panel

Post by highend »

I can upload a Windows IDE executable with the change
That would be great!
User avatar
kenmo
Addict
Addict
Posts: 1967
Joined: Tue Dec 23, 2003 3:54 am

Re: Remember the current procedures positions on the right panel

Post by kenmo »

You caught me at a good time... I pushed a (Windows) IDE build with the procedure browser change.

GitHub branch showing changes:
https://github.com/fantaisie-software/p ... wser-build

The file PureBasic-PreserveProcBrowser.exe
https://github.com/kenmo-pb/purebasic/b ... rowser.exe
(click Download or View Raw)
User avatar
ChrisR
Addict
Addict
Posts: 1127
Joined: Sun Jan 08, 2017 10:27 pm
Location: France

Re: Remember the current procedures positions on the right panel

Post by ChrisR »

kenmo wrote: Sun Aug 28, 2022 7:46 pm I have a patch on GitHub that adds this feature to the IDE, but it's Windows only (uses API to get/set listview position)
I rebuilt the windows x64 IDE with your patch, it works fine and it's really helpful. Thanks for adding this feature :)

I appreciate all the small UI improvements you made, eg this one or Allow Enter key to open selected Project File in list, Add "Show in Folder",...
Do you have or would it be possible to have a branch, based on the official branch, which would regroup all your main additions, your improvements.
It's sometimes this kind of little thing that make the difference in use.

#
t-harter wrote: "I really don't like features that work on only some OS. It will just look like a bug to users who use PB on more than one platform when things that they are used to from one platform simply don't work on another."
I disagree here, even if it's Windows only, it should be included in the official "devel" branch.
After all, it is rather a dysfunction correction and not an improvement. I mean it should be like this, on all 3 platforms, since the beginning.
With time, there should be a fix for Mac or Linux, as well, I hope.
But at least, by integrating it into the official branch, we would have one with the right functionality and it's really useful.
I can understand the use of the lowest common denominator in the case of PB functions, to have the same syntax on the 3 platforms. But here, in my view, it does not make sense.
Axolotl
Enthusiast
Enthusiast
Posts: 435
Joined: Wed Dec 31, 2008 3:36 pm

Re: Remember the current procedures positions on the right panel

Post by Axolotl »

Hey kenmo and ChrisR,

I would like to support your opinion. the "on all platforms" policy among others prevents me from editing the IDE.
My suggestion to distinguish single plattform implementations from an error, you can also show a "Not supported on <OS>" message. e.g. in an improved MessageRequester, which also has a checkbox for "do not show again".
But that's probably easy to say when you're on Windows. To me, the Linux and MAC implementations look infinitely more complicated.
Mostly running PureBasic <latest stable version and current alpha/beta> (x64) on Windows 11 Home
Post Reply