INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Bug(?) / Feature Request: Allow 3 states for the <Tree> Expand button  (Read 760 times)

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 849

Currently I find that the Tree expand button (used in the left side panel Organization Tree and in the right side of the Options Popup Tree) only allows 2 states (see first attachment, shown for the attached 2-State image file).  I'd really like to liven things up a bit by adding a mouseover subimage for the Tree expand button (see the attached 3-State image file).  Mouseover text and background colors for the line work nicely, but I'd also like the button itself to temporarily change on mouseover.

In the Standard skin's main.xml:
<Tree>
. . .
    <Entry Name="ExpandButton" Bitmap="Tree_ExpandButton.png" NumberImages="2" />
. . .
</Tree>


Bug(?):  Modify to NumberImages="3" and supply an appropriate 3-State image. The button shows no mouseover action and mistakenly displays the "Over" (2nd subimage) for the "Pressed" state.

Feature Request:   Please make "ExpandButton" behave like other 3-State buttons (Normal, Over, and Pressed subimages) if possible, or provide some other way to skin a mouseover state subimage for it.  Behavior should carry over analogously to other Tree lists, such as the Options Popup Tree.

Note I can get the desired mouseover response for the Action Window buttons, but those are programmatically a somewhat different case.

Thank you.

11/4/2024  Clarify the bug description.  Attach 2-State PNG file (works as shown) and 3-State PNG file (MC displays only its first 2 button subimages - no mouseover action), both designed for dark skins.

11/3/2024 - edited for clarity.
Win 11 Pro 64-bit | MC 33.0.37
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42441
  • Shoes gone again!
Re: Bug(?) / Feature Request: Allow 3 states for the <Tree> Expand button
« Reply #1 on: November 25, 2024, 01:03:23 pm »

Coming next build:
NEW: Added support for three state tree expand buttons to show a mouse over image.

Thanks for the help.
Logged
Matt Ashland, JRiver Media Center

EnglishTiger

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1113
Re: Bug(?) / Feature Request: Allow 3 states for the <Tree> Expand button
« Reply #2 on: November 29, 2024, 12:04:53 am »

Unfortunately this suggestion has not been fully thought through.
The current 2 sub-images, the expand and contract buttons, in the Bitmap act as the pressed state for each other in the same way that the normal state of the Player Bar Pause Button acts as the pressed state for the Play Button.

So it the "2 sub-image" button is replaced by  "3 sub-image" button in theory one of the sub-images is going to be the hover state for both the expand and contract buttons.

The more logical approach would be to replace the current 2-sub-images with 4 sub-images so that image 1 would be the Normal State for the Expand Button, image 1 its Hover State, image 3 the Normal State for the Contract button and image 4 its Hover State.

In all of my skins the Tree/Options Window Expand/Contract Window Buttons are the Hover State Image for the Platforms Maximise and Minimise Windows Control Buttons.
Whilst the buttons used in the tag window are the actual Windows Control Buttons.

So the only time I would change those existing Expand/Contract Buttons would be if the 2 sub-images were replaced by 4 sub-images or I could get rid of the need for that set of images if the Skinning Engine was modified to allow me to use the Platforms Window Control Buttons instead.
Logged
Apple Mac Mini Desktop Computer with M4 Pro chip with 12 core CPU and 16 core GPU: 24GB Unified Memory, 512GB SSD Storage, Gigabit Ethernet, 3 Thunderbolt5 + 2USBC ports.

markf2748

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 849
Re: Bug(?) / Feature Request: Allow 3 states for the <Tree> Expand button
« Reply #3 on: November 29, 2024, 11:13:42 am »

So it if the "2 sub-image" button is replaced by  "3 sub-image" button in theory one of the sub-images is going to be the hover state for both the expand and contract buttons.

The more logical approach would be to replace the current 2-sub-images with 4 sub-images so that image 1 would be the Normal State for the Expand Button, image 1 2 its Hover State, image 3 the Normal State for the Contract button and image 4 its Hover State.
@ET Thank you for posting this.  I had it in the back of my mind that having only a single hover image would be a challenge, though I could live with it for round buttons.  For arrowheads, one might consider for example a hover image with arrowhead pointing 45 degrees down, or a curved line with arrowheads at both ends, or something neutral like an asterisk, all of which would cover changes in both directions in a new way!  :)

But I agree that 4 subimages, as you describe, is a more flexible solution.  It allows one to visually address the "direction" of the implied state change with two different hover images.  For example, highlight each state button individually as is often done with the two play/pause control button sets.  Or hover with a highlighted image of the target state.  This would differ from MC's most common button conventions and would benefit from documentation, but it is not unprecedented to do so (for example the Frame RadioButton described in the document Standard View Skinning SDK).  Hopefully, under the hood Matt can still make it compatible with existing 2-subimage implementations when NumberImages="2".
Logged
Pages: [1]   Go Up