Jump to content




Monitor Resize Event


  • You cannot reply to this topic
6 replies to this topic

#1 GravityScore

  • Members
  • 796 posts
  • LocationLand of Meh

Posted 18 February 2013 - 08:57 PM

Hey,

Could we have a monitor resize event, that's queued whenever an attached monitor is resized due to more monitor blocks being added to it? Could the event also include the side, so programs are able to update relevant window sizes/locations/background colours for each attached monitor?

#2 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 18 February 2013 - 08:59 PM

this would be nice!

there are ways to do this, but an event for it would be nice just to have { "monitor_resize" } but preferably { "monitor_resize", "left" }

#3 Kingdaro

    The Doctor

  • Members
  • 1,636 posts
  • Location'MURICA

Posted 18 February 2013 - 09:06 PM

This'd be pretty cool to have, as there isn't much of an efficient way to do this instantly.

#4 Shnupbups

  • Members
  • 596 posts
  • LocationThat place over there. Y'know. The one where I am.

Posted 18 February 2013 - 10:02 PM

YES!

Epicness this be.

#5 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 19 February 2013 - 04:29 AM

You could just have a timer event fire every once in a while, maybe, every five seconds. From that, you could recheck the size of the monitor, and if it changed, you can just redraw the screen. It's not too difficult, just a little annoying really.

#6 Lyqyd

    Lua Liquidator

  • Moderators
  • 8,465 posts

Posted 19 February 2013 - 04:46 AM

Certain things are already using the event "window_resize" to tell programs that the surface they can draw to has changed in size. ;)

The side being specified isn't particularly possible, as two sides could change at once. It is better to simply fetch the new size and redraw the interface.

#7 Cloudy

    Ex-Developer

  • Members
  • 2,543 posts

Posted 19 February 2013 - 06:56 AM

Agreed, this would be nice.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users