Anim example

Discuss GUI programming with the MUI Royale plugin here
Post Reply
User avatar
r-tea
Posts: 123
Joined: Tue Feb 16, 2016 11:48 pm
Location: Zdzieszowice, Poland
Contact:

Anim example

Post by r-tea » Mon Apr 22, 2019 8:42 am

There is an Anim example within MUIRoyale drawer.
I try to find out how to adapt the size of a brush to the Hollywood object area.
I suppose there is a part of code where it takes place, bu I can't understand how msg.Width "knows" we need exactly the Hollywood display area?

Code: Select all

	; has the size of our Hollywood class changed?
	If msg.Action = "SizeWindow"
      		swidth = msg.Width
		sheight = msg.Height
      		CreateBrush(1, swidth, sheight)
      		Return
   	EndIf

User avatar
airsoftsoftwair
Posts: 3110
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Anim example

Post by airsoftsoftwair » Tue Apr 30, 2019 8:49 pm

The "SizeWindow" event is triggered every time the window is resized and then msg.Width and msg.Height will contain the current window size.

User avatar
r-tea
Posts: 123
Joined: Tue Feb 16, 2016 11:48 pm
Location: Zdzieszowice, Poland
Contact:

Re: Anim example

Post by r-tea » Fri May 03, 2019 7:34 pm

But it takes the size of the whole window (including borders), and the brush is odopted only to the Hollywood display size.

User avatar
airsoftsoftwair
Posts: 3110
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Anim example

Post by airsoftsoftwair » Sat May 04, 2019 12:53 pm

No, it should report the size of the Hollywood widget, not of the MUI window...

User avatar
r-tea
Posts: 123
Joined: Tue Feb 16, 2016 11:48 pm
Location: Zdzieszowice, Poland
Contact:

Re: Anim example

Post by r-tea » Sat May 04, 2019 7:48 pm

Thank you. I finally managed with it.

Post Reply