Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up Try the site in https mode Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Icons over Displays  (Read 2561 times)

0 Members and 1 Guest are viewing this topic.

froggerman

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 311
  • Last login:March 01, 2015, 03:23:14 am
  • You want how many buttons?!
Icons over Displays
« on: April 28, 2007, 12:00:50 am »
This is probably a silly question, but I would like to put a clickable icon on top of a display. If I do this the display cannot be seen. If I put a clickable icon on top of a non-clickable icon, there is no problem.

Why can I not put a clickable icon on top of a display?


Chris

  • Moderator
  • Trade Count: (+2)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 4574
  • Last login:September 21, 2019, 04:59:49 pm
    • Chris's MAME Cabinet
Re: Icons over Displays
« Reply #1 on: April 30, 2007, 08:45:41 am »
This is probably a silly question, but I would like to put a clickable icon on top of a display. If I do this the display cannot be seen. If I put a clickable icon on top of a non-clickable icon, there is no problem.

Why can I not put a clickable icon on top of a display?
Is it the display that can't be seen or the icon?

For performance reasons, each UI element updates individually.  When the display re-draws itself, it doesn't know that there's an icon in front of it that also needs to be redrawn, so the icon would "disappear".  When you move your mouse over where the icon was, it needs to redraw itself so it suddenly "re-appears".  To handle this properly, I would need a way to tell each element where it's supposed to be in the "z-order" and then after every update work up through the Z-order and find every element that overlaps to see if it needs to be redrawn, then repeat the process with any redrawn elements, which may trigger the process with more elements.  And of course there's the issue of clicks and mouse-overs; those events would go to all objects that overlap in a particular space. None of this is impossible to deal with, of course, but it's easier to just say "Don't do that".  I'll take a look at this as I redesign the display system and see if there's something I can do about it.

--Chris
--Chris
DOSCab/WinCab Jukebox: http://www.dwjukebox.com

froggerman

  • Trade Count: (0)
  • Full Member
  • ***
  • Offline Offline
  • Posts: 311
  • Last login:March 01, 2015, 03:23:14 am
  • You want how many buttons?!
Re: Icons over Displays
« Reply #2 on: May 01, 2007, 11:05:30 am »
Hi Chris,

Thanks for the explanation. I was trying to make a clickable area on top of the credit display. The problem was that when I did this you can no longer see the credit display. The reason for trying to do this was to allow for another touch-button on a busy UI.

No worries, I moved the icon above the display so that it doesn't cover any part of it.

Chris

  • Moderator
  • Trade Count: (+2)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 4574
  • Last login:September 21, 2019, 04:59:49 pm
    • Chris's MAME Cabinet
Re: Icons over Displays
« Reply #3 on: May 01, 2007, 12:33:43 pm »
Hi Chris,

Thanks for the explanation. I was trying to make a clickable area on top of the credit display. The problem was that when I did this you can no longer see the credit display. The reason for trying to do this was to allow for another touch-button on a busy UI.

That's odd.  The worst that should happen is that you occasionally lose part of the button image.  Can you send me the skin file with your modifications?  Something I did to enable transparent display backgrounds could be wrong.

--Chris
--Chris
DOSCab/WinCab Jukebox: http://www.dwjukebox.com