Ability to allow plugins to query the filenames of current ButtonBars from TC

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
diopter
Junior Member
Junior Member
Posts: 31
Joined: 2017-02-02, 06:42 UTC
Location: Germany

Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *diopter »

To extend the ButtonBar functionality of the TC, it would be nice if plugins or external programs and scripts could find out the file names of the current ButtonBars.
That should be very easy for Mr. Ghisler to realize:
Just insert a Windows API call in the right place in ButtonBar code:
SetWindowText(ButtonBarWnd, ButtonBarFileName);

Zur Erweiterung der ButtonBar-Funktionalität des TC wäre es schön, wenn Plugins oder auch externe Programme und Scripts die Dateinamen der aktuellen ButtonBars in Erfahrung bringen könnten.
Das sollte für Herrn Ghisler sehr leicht zu realisieren sein:
Einfach an der richtigen Stelle im ButtonBar-Code einen Windows-API-Aufruf einfügen:
SetWindowText(ButtonBarWnd, ButtonBarFileName);
User avatar
Dalai
Power Member
Power Member
Posts: 9386
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *Dalai »

diopter wrote: 2018-09-17, 04:30 UTCTo extend the ButtonBar functionality of the TC, it would be nice if plugins or external programs and scripts could find out the file names of the current ButtonBars.
To do what exactly? Can you please elaborate more on what you intend to do with this information? What's your use case?

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
User avatar
ts4242
Power Member
Power Member
Posts: 2081
Joined: 2004-02-02, 20:08 UTC
Contact:

Re: Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *ts4242 »

diopter wrote: 2018-09-17, 04:30 UTCit would be nice if plugins or external programs and scripts could find out the file names of the current ButtonBars.
Button Bar Editor can do, all it needs is knowing the main bar file by reading this value Buttonbar under Buttonbar section. All sub-bars file names are stored in the main bar file.
diopter
Junior Member
Junior Member
Posts: 31
Joined: 2017-02-02, 06:42 UTC
Location: Germany

Re: Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *diopter »

...is knowing the main bar file by reading this value Buttonbar under Buttonbar section.
You are right when TC starts, but then user can load other buttonbars and a plugin don't know their file names.
If a plugin could request the filenames of the current active buttonbars, it could change the icon of a button to show different states, for example.
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *MVV »

If a plugin could request the filenames of the current active buttonbars, it could change the icon of a button to show different states, for example.
But TC caches icons so you have to delete cache file and open/apply buttonbar dialog after changing an icon in BAR file...
diopter
Junior Member
Junior Member
Posts: 31
Joined: 2017-02-02, 06:42 UTC
Location: Germany

Re: Ability to allow plugins to query the filenames of current ButtonBars from TC

Post by *diopter »

What do think how I would change an icon ?
I know the file format of .br2 and can change the icon in the cache file, but therefor i must know the filename...
Open/apply buttonbar is not needed, cm_ReloadBarIcons reloads the icons.
Post Reply