7+ Taskbar Tweaking Library

7+ Taskbar Tweaking Library is a library for manipulating the taskbar of Windows 7 and above. It’s inspired by the 7+ Taskbar Tweaker program, and it allows you, as a programmer, to manipulate the Windows taskbar, which is virtually impossible to do with the documented Windows API.

You can take a quick look at the provided API here. For a more extensive look, refer to the examples which are provided together with the library.

In general, the library allows you to:

  • Get extensive information about the taskbar items and groups on all taskbars.
  • Reorder taskbar items, and reorder buttons within groups.
  • Set per-AppId settings.

For example, if you’d like to have the taskbar button of your program to never show labels, you can easily do it with the library:

Download

You can get 7+ Taskbar Tweaking Library here:

zip TTLib.zip (396.14 kB)

Please note that the library is free for non-commercial use only. If you’re interested in using the library for a commercial application, please contact me.

Posted in Programming by RaMMicHaeL at October 31st, 2014.
Tags:

44 Responses to “7+ Taskbar Tweaking Library”

  1. staticvoid says:

    Nice work. Thanks 🙂

  2. DebugErr says:

    Don’t know if this is good or not. Many noobish programs will now mess around with the taskbar. Better avoid these.

    • RaMMicHaeL says:

      If you prevent programs from doing stupid things, then you also prevent them from doing clever things. -Raymond

      • DebugErr says:

        Of course. The problem is, there are always black sheep. Ask Microsoft why they removed program access to the pinned start menu item list. Because every stupid program feeling important enough would pin itself there, probably with an uppercase title.
        These programs here will probably override your enjoyed setting of having grouped buttons and will always show their – probably uppercase – title. At least you should add an option to the 7+ taskbar tweaker to ignore such settings if it becomes more and more common that programs mess with _your_ settings.

  3. Javan MIller says:

    Will this be made available to Windows 10 technical preview?

  4. Retired Engineer says:

    Some great ideas are being implemented in 7TT. Contribution is on its way.

  5. Amazing dude!!! your 7+ Taskbar Tweaker is a MUST HAVE!
    I can’t live (using Windows 7 or 8) without it !

    take a look at my software: https://sourceforge.net/projects/clipboardextra/

  6. E.Hatt-Swank says:

    Just wanted to say thank you for creating this very useful tool. I have to use Windows 7 for my job, and regularly have 10-20 Putty sessions open to various servers. The W7 taskbar behavior of shifting icons around randomly is immensely frustrating and a real productivity-killer, because i need the icons to remain open in the order I opened them, so i can hop from one to another quickly. Your tool saved the day. Brilliant!

  7. Rebelane says:

    Hi, Just a grateful thanks and my appreciation.
    Stay Stafe.

  8. KEALHOVIK says:

    Does this version work with Win 10 Anniversary update?

    • RaMMicHaeL says:

      Are you referring to the library, or to the 7+ Taskbar Tweaker program?
      For the former, it doesn’t. It needs to be updated.
      For the latter, there’s a beta version which you can try.

      • KEALHOVIK says:

        Thanks for the answer and amazing software. Gonna wait for updated library

        • RaMMicHaeL says:

          May I ask, what are you using the library for?
          I didn’t get much feedback for the library ever since it was released, and I’m curious to know whether it is being used, and if it is, then what are its uses.

          • KEALHOVIK says:

            I just find this option “cycle between taskbar buttons with mousewheel” after installing beta and running through setup again. I really like it but it’s gonna be more productive to use mousewheel in combine with some hotkey so you don’t need to move your cursor to the taskbar. So i wanted to recreate this function with ahk script using your library. Although i have no experience working with libraries and not much experience in programming actually, but i wanted to create something that would be actually usable.

            • RaMMicHaeL says:

              Sounds interesting, good luck with the project. I have just updated the library. Feel free to contact me if you need any help, and it would be interesting to look at the result when it’s done.

  9. Lkytal says:

    I tried but seems not working on windows10 1607 x64.

    • RaMMicHaeL says:

      What’s not working? Are you seeing an error message? You have to provide more details so I’ll be able to help you.

      • Lkytal says:

        I build example “taskbar_button_manipulator” with vs2013, run it and select “never group” (and other options), no error occurs, output message was successfull, but no effect.

        • RaMMicHaeL says:

          To see the effect of the grouping option, you’ll need to launch more than one instance of the program.
          The “Show labels” option, on the other hand, should work even with one instance.

          Also, make sure that you are compiling for the right architecture (32 or 64-bit).

          If it still doesn’t work, please provide the full output of the console window.

          • Lkytal says:

            I launch two instance of firefox with no effect while your 7+ Taskbar Tweaker program works, have no idea why.
            Running your example generate standard output as below:
            Initializing 7+ Taskbar Tweaking library…
            Loading 7+ Taskbar Tweaking library into explorer…
            Adding AppId to list… Operation succeeded
            Nothing seems go wrong…

            • RaMMicHaeL says:

              The “taskbar_button_manipulator” demo only controls its own buttons. It shouldn’t affect Firefox, or any other program. See the code for more details.

              • Lkytal says:

                I see, so I have to manually get my target’s ApplicationId in order to control it? May I ask how you control the whole taskbar icons, by enum all of it? thx.

                • RaMMicHaeL says:

                  I see, so I have to manually get my target’s ApplicationId in order to control it?

                  Yes.

                  May I ask how you control the whole taskbar icons, by enum all of it? thx.

                  You cannot do that with the library. It was designed to control your own programs, not the global system settings.

                  May I wonder what your goal is?

                  • Lkytal says:

                    I’m trying to implement a extension program to control the behavior of the target program, one of it’s function is to disable the target’s icon combination, is their any solution?

  10. José Rebelo says:

    Is it / would it be possible to move the taskbar buttons handle programatically? (this, right next to Chrome: https://i.imgur.com/KrnsNV3.png, it shows up when the taskbar is unlocked).

    I was wondering if it would be possible to keep the taskbar buttons centered on the screen using it.

  11. Chris_Bognar says:

    Curious to whether the 7TT library has the necessary functions implemented to write a small exe for changing a program’s AppID passed as a command-line parameter. Newly into programming, would like to try this project if the base functions are in the library, because I need both the practice and the functionality. I have rudimentary C++ skill, but am still struggling reading the header declarations. I don’t believe I see any functions that set AppID for Taskbar buttons, but I may be too new to see it.

    • RaMMicHaeL says:

      You don’t need the 7+ Taskbar Tweaking Library change a window’s AppID. Windows provides this functionality.
      There’s actually an implementation of such a function in the file Examples\taskbar_button_manipulator\wnd_set_appid.c in TTLib.zip.

      • Chris_Bognar says:

        You pointed me in the right direction. I was able to read and understand what’s happening in the examples. If I’m not mistaken, you are setting the AppID of the console window to taskbar button manipulator. I didn’t initially see this effect correctly because I was using ConEmu, which was injecting itself as a console wrapper, and when I stopped the ConEmu wrapper, it worked properly.

        Thank you for the quick response, very much appreciated.

  12. Clayton Rupe says:

    Thank you so much! Please continue to keep up the good work!

  13. Alex says:

    Hi,
    Just wanted to check if this library is still working/supported as of Windows 10 1903 update?
    I pulled the content down and can compile after putting TTLib64.dll in the binary folder but am currently unable to run the included examples. Output:

    Initializing 7+ Taskbar Tweaking library…
    Loading 7+ Taskbar Tweaking library into explorer…
    TTLib_LoadIntoExplorer() failed with error 105

    taskbar_button_printer fails with error 135 instead.

    In both cases, explorer then crashes and console exits (interestingly, this also happens to me when rearranging taskbar with 7+ Taskbar Tweaker 5.7 – maybe 1903 broke something?).

    Is there a step I’m missing with running here?
    I was hoping to implement key bindings to ‘Reorder taskbar items’ by moving a taskbar item to the left/right, which was the only thing feature I felt was missing from your 7+ Taskbar Tweaker.

    Thanks in advance and thanks for releasing this library.

    • RaMMicHaeL says:

      Hi Alex,

      The latest version of the library is v5.6.0.1. The library shares code with 7+ Taskbar Tweaker, and you can deduce the supported Windows versions from the tweaker’s changelog. Currently, Windows 10 October 2018 Update is the latest supported version by the 7+ Taskbar Tweaking Library. I’d need to update it to v5.7 to be in sync with the tweaker and support Windows 10 May 2019 Update. I’ll try to do that in the following days once I find some spare time.

      • Alex says:

        Thanks for the prompt response and the helpful answer, I’ll definitely look forward when the library is updated to 5.7!
        Cheers.

        • RaMMicHaeL says:

          Hi again,

          I’ve updated the library to 5.7 🙂

          • Alex says:

            Hi again RaMMichael,

            I’ve been using the library for the last couple months to reorder taskbar and it works a treat for single taskbar usecase (Thanks again)!

            However, I am running into issues in multi-monitor situations, particularly operating on the handle returned by TTLib_GetSecondaryTaskbar. The program seems to crash when trying to call anything on the second taskbar (even the taskbar_content_printer example crashes when trying to print secondary taskbar). Could this be a bug in the updated dll?

            Second, there isn’t an api available in the library for Set active Button/ButtonGroup which would be useful for my usecase of creating keybindings to manipulate the taskbar. I see there’s a place for feature requests for the main Taskbar Tweaker tool, but not this library – where’s the best place to request/gauge the effort required to expose this functionality to the library?

            I’ve already found the library really useful so far and am super grateful for its existence – looking forward to any response.

            • RaMMicHaeL says:

              Hi Alex,

              I’ve been using the library for the last couple months

              Interesting. Have you considered releasing the source code? It would be interesting looking at code using the library. For now there’s only Virtuoz.

              The program seems to crash when trying to call anything on the second taskbar

              I’ve just updated the library to v5.8. Look at the tweaker’s changelog, perhaps you’re using a Windows version which is no longer compatible with v5.7.

              there isn’t an api available in the library for Set active Button/ButtonGroup

              If I understand correctly, you can just grab the window handle and make it the foreground window with a function such as SetForegroundWindow.

              • Alex says:

                Thanks for the reply!

                Have you considered releasing the source code?

                I held back on putting it anywhere earlier because of the limitation of only reordering groups on the main taskbar, but what’s working so far is here.

                perhaps you’re using a Windows version which is no longer compatible with v5.7

                I’m still running 1903 so wouldn’t think that’s the case but I tried the updated library, thanks for the heads up! Unfortunately the same issue is still happening on a laptop attached to external monitor.

                The symptom is mouse movements slowing to a crawl, then behaviour that’s similar to restarting explorer.exe or trying to drag a ButtonGroup by mouse while debugger is attached to the taskbar modifying code.

                The actual .exe using TTLib.dll stays open this time and just hangs at the point where you tried to call an api on secondary taskbar. I’ve attached a screenshot for taskbar_contents_printer.exe trying to call TTLib_GetTaskbarMonitor(hTaskbar)) after getting the window handle here. This is taken right after the taskbar ‘restart’ is observed (it eventually repopulates with all the ButtonGroups) – any pointers on how to proceed from here (do I need to update to 1909)?

                you can just grab the window handle and make it the foreground window with a function such as SetForegroundWindow.

                Appreciate the advice, still new to poking around in Win32 land – I’ll give that a shot too.

  14. Alex says:

    Looks like it works a charm now – thanks for the quick turnaround!

  15. Hortiks says:

    Thanks a lot for this usefull application, can’t use my navigator without it now 🙂
    I would just know if you use a service to start the app and if i can delay it ?

    • RaMMicHaeL says:

      You’re commenting under the 7+ Taskbar Tweaking Library page, but you’re probably referring to the 7+ Taskbar Tweaker tool. It doesn’t use a service, the startup is set in the registry. There’s no built-in way to delay the startup, but you might be able to use a third party tool or a custom solution (such as a script) for that.

Leave a Reply