You are not logged in.

#1 2017-08-13 19:53:27

jlfh0816
Member
From: Plougonvelin (France)
Registered: 2017-01-14
Posts: 21

Behavior of icons on mouseover

Hello,
When hovering your cursor on top icons, they become ‘highlighted’ and their appearance change and stay that way until the cursor leaves them. This intrigued me… Would you know an explanation and/or a tutorial detailing the exact process? For instance, is it a second icon being displayed or is it another mecanism altogether? Is there any way to modify/customise it?
Thank you for ‘enlightening’ me!


Xubuntu 18.04.4 LTS (64 bits)

Offline

#2 2017-08-13 20:17:48

damo
....moderator....
Registered: 2015-08-20
Posts: 6,734

Re: Behavior of icons on mouseover

Do you mean the icons in the Tint2 panel? If so then the behaviour is set in the tint2rc config file: see the mouse effect section in the Tint2 wiki, and the Task icons settings.


Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt  «» BunsenLabs on DeviantArt

Offline

#3 2017-08-13 20:29:24

jlfh0816
Member
From: Plougonvelin (France)
Registered: 2017-01-14
Posts: 21

Re: Behavior of icons on mouseover

@damo
Thanks for your quick answer! I did not mean the Tint2 panel though, but… let me give you an example. When using a file manager like Nemo to browse my folders, they become highlighted on mouseover. Is there a way to change this behavior? For instance, having non-active folders be closed then on mouseover the icon would change into an opened folder. Is this feasible?


Xubuntu 18.04.4 LTS (64 bits)

Offline

#4 2017-08-14 05:39:50

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Behavior of icons on mouseover

jlfh0816 wrote:

When hovering your cursor on top icons, they become ‘highlighted’ and their appearance change and stay that way until the cursor leaves them. This intrigued me… Would you know an explanation and/or a tutorial detailing the exact process?

it depends on the application.
Usually it's GTK, the UI toolkit used for most applications (filemanager, browser etc).
It depends entirely on this software and the underlying toolkit if this mechanism is available, or if there's an option to configure/customize it.
The mechanism itself is coded in some programming language and needs to be compiled.
I guess that internally a semi-transparent overlay is created, but a complete replacement with a different pixmap is also possible and fairly common esp. with more traditional software.

you can throw together various search terms and see what you find, for example.
GTK is still an example, you could search how this is done in QT, tint2, Windows10, CSS, etc.
If you wanted to go into the programming of GTK apps, I guess this is the place to start.

Last edited by ohnonot (2017-08-14 05:42:01)

Offline

#5 2017-08-14 17:07:25

jlfh0816
Member
From: Plougonvelin (France)
Registered: 2017-01-14
Posts: 21

Re: Behavior of icons on mouseover

@Ohnonot
Thank you for the detailed answer and the links! It seems like I have quite some work ahead of me. I will read your links and more documentation, see what I can do and keep you informed. Hopefully I will find a way to make this work and share it.  smile


Xubuntu 18.04.4 LTS (64 bits)

Offline

#6 2017-08-14 18:41:32

ohnonot
...again
Registered: 2015-09-29
Posts: 5,592

Re: Behavior of icons on mouseover

^ what exactly do you want to get to work? i thought you were just curious...

Offline

#7 2017-08-15 09:37:06

jlfh0816
Member
From: Plougonvelin (France)
Registered: 2017-01-14
Posts: 21

Re: Behavior of icons on mouseover

@Ohnonot
Oh I am curious indeed to know whether there is a way to customize the behavior of the icons I hover my mouse over.
My idea is in itself quite simple: right now, icons become highlighted on mouseover. I would like to change this to having the icon increase in size, or a new icon (e.g. an opened folder icon, like an opened book). And who knows, maybe even a basic animation like the icon rotating, that or the icon change being animated! One can dream!
As I am not that knowledgeable on the matter, the aim of my previous posts was to gather information from savvier users such as yourself. Is it feasible? If so, to what extent? Maybe explore some lines of thought or useful links. Which you did, and I thank you again, I sincerely appreciate! smile

For now though, I will wait until my vacation early September to take a closer look.


Xubuntu 18.04.4 LTS (64 bits)

Offline

#8 2017-08-15 10:26:44

brontosaurusrex
Middle Office
Registered: 2015-09-29
Posts: 2,755

Re: Behavior of icons on mouseover

From my shallow observation most stuff will not use 2ndary image/animation at all (like onMouseOver).
- In tint2, there is execp_has_icon which may or may not be used for some animation-like purposes.
- In wbar, you can define zoom, transparency and some fx, but again there is no easy way to switch to another image afaik.
- gtk3 css stuff is just a small subset, but there might be something hiding in there.
^ Just examples.

Last edited by brontosaurusrex (2017-08-15 10:28:21)

Offline

#9 2017-08-15 12:12:00

jlfh0816
Member
From: Plougonvelin (France)
Registered: 2017-01-14
Posts: 21

Re: Behavior of icons on mouseover

brontosaurusrex wrote:

- gtk3 css stuff is just a small subset, but there might be something hiding in there.

That is indeed what I ended up thinking. Hopefully I will manage something with it. A shame GTK's CSS is not exactly the same as HTML's. hmm
Still, thank you for the input. It confirms most stuff modify the image (usually with compiled code) which makes the task much harder.


Xubuntu 18.04.4 LTS (64 bits)

Offline

#10 2017-08-16 18:18:54

tknomanzr
BL Die Hard
From: Around the Bend
Registered: 2015-09-29
Posts: 1,057

Re: Behavior of icons on mouseover

It honestly depends on where the icons are located. Tint2 has an implementation as does gtk. GTK uses css for the highlighting just as  a webpage would. Tint2 uses its own implementation. A peek at the tint2 wiki should help.

Offline

Board footer

Powered by FluxBB