<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>getting fullscreen button on window</title>
		<link>http://www.allegro.cc/forums/view/607204</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Tue, 03 May 2011 03:24:38 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>


hi,</p><p> Does allegro provide a way to recieve a signal that the fullscreen button has been pressed or do we need to use platform specific code for that.</p><p>You know what I mean : the middle button on the top of the window.</p><p>using A5</p><p>Sorry if this has already been asked somewhere else.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 02:23:18 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>If the window is set to be resizable, then you&#39;ll get a <span class="source-code">ALLEGRO_EVENT_DISPLAY_RESIZE</span> event. </p><p>What do you want to do when the window is maximized?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Tue, 03 May 2011 02:25:28 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Thanks. Switch to fullsreen.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 02:37:06 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Are you using <span class="source-code">ALLEGRO_FULLSCREEN_WINDOW</span> flag? You can toggle that flag to easily switch back and forth.</p><p>But I&#39;m not sure if Allegro automatically makes the maximize button switch to full screen with that flag set. It would be nice if it did.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Tue, 03 May 2011 02:45:59 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>That&#39;s not what it does though. The maximize button tells the window manager (even on windows) to make the window fill the available screen area that isn&#39;t taken up by any docks (start bar) or the window frame itself.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Tue, 03 May 2011 02:46:10 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915806#target">Thomas Fjellstrom</a> said:</div><div class="quote"><p>  The maximize button tells the window manager (even on windows)
</p></div></div><p>Yeah but I&#39;ve seen a few Windows applications that override the maximize button to go full screen. It would be nice if Allegro could do that on windows that were set with <span class="source-code">FULLSCREEN_WINDOW</span>.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Tue, 03 May 2011 02:48:00 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915805#target">Matthew Leverton</a> said:</div><div class="quote"><p>

Are you using ALLEGRO_FULLSCREEN_WINDOW flag? You can toggle that flag to easily switch back and forth.</p></div></div><p>

No. Does it mean al_create_display() has to be recalled ?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 02:48:41 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915808#target">William Labbett</a> said:</div><div class="quote"><p> No. Does it mean al_create_display() has to be recalled ?
</p></div></div><p>I&#39;ve not used it, but my understanding is that the switch is automatic. Just call <span class="source-code"><a href="http://www.allegro.cc/manual/al_toggle_display_flag"><span class="a">al_toggle_display_flag</span></a><span class="k2">(</span><span class="k2">)</span></span> with the proper display and flag.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Tue, 03 May 2011 02:50:05 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915807#target">Matthew Leverton</a> said:</div><div class="quote"><p>Yeah but I&#39;ve seen a few Windows applications that override the maximize button to go full screen. It would be nice if Allegro could do that on windows that were set with FULLSCREEN_WINDOW.</p></div></div><p>I suppose it&#39;d be nice to get a new event for the maximize button. But how many people would actually expect the maximize button to do anything other than maximize? I think its a bad design call.</p><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915808#target">William Labbett</a> said:</div><div class="quote"><p>No. Does it mean al_create_display() has to be recalled ?</p></div></div><p>use ALLEGRO_FULLSCREEN_WINDOW instead of ALLEGRO_FULLSCREEN and you can switch between fullscreen and windowed modes. Note though, it means you&#39;re stuck with what ever resolution the user has set at the time, so you&#39;ll have to handle all kinds of resolutions and sizes.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Tue, 03 May 2011 02:51:03 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>No, you just call al_toggle_display_option(ALLEGRO_FULLSCREEN_WINDOW). And you don&#39;t have to have it set to use that. It either has to 1) start off as a windowed display or 2) start off in FULLSCREEN_WINDOW mode.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Trent Gamblin)</author>
		<pubDate>Tue, 03 May 2011 02:51:27 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>As easy as that ? Cool.</p><p>only thing - in order to call the toggle function I need a way to do :</p><div class="source-code snippet"><div class="inner"><pre><span class="k1">if</span><span class="k2">(</span> middle resize button pressed <span class="k2">)</span>
<span class="k2">{</span>
   toggle<span class="k2">(</span><span class="k2">)</span><span class="k2">;</span>
<span class="k2">}</span>
</pre></div></div><p>

Is there a specifc event for that button ?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 02:52:55 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915810#target">Thomas Fjellstrom</a> said:</div><div class="quote"><p> I suppose it&#39;d be nice to get a new event for the maximize button. But how many people would actually expect the maximize button to do anything other than maximize? I think its a bad design call.
</p></div></div><p>It&#39;s not for every situation, but I think given the use of <span class="source-code">FULLSCREEN_WINDOW</span>, it make sense (particularly if the window is not resizable).</p><p>But being able to catch a <span class="source-code">MAXIMIZE</span> event would be sufficient. (Acknowledge the resize, and then switch to full screen.) However, you may want to use maximize but not let the window be resizable. Not sure if Allegro supports that sort of thing or not.</p><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915812#target">William Labbett</a> said:</div><div class="quote"><p> Is there a specifc event for that button ?
</p></div></div><p>No.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Matthew Leverton)</author>
		<pubDate>Tue, 03 May 2011 02:54:40 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
It would nice to be able to use the button for switching to fullscreen but then if it was used only for that then they&#39;d be no way to set a maximum windowed mode.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 03:03:01 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title"><a href="http://www.allegro.cc/forums/thread/607204/915811#target">Trent Gamblin</a> said:</div><div class="quote"><p>No, you just call al_toggle_display_option(ALLEGRO_FULLSCREEN_WINDOW). And you don&#39;t have to have it set to use that. It either has to 1) start off as a windowed display or 2) start off in FULLSCREEN_WINDOW mode.</p></div></div><p>Of course, you&#39;re right.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Tue, 03 May 2011 03:04:04 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>As it stands then the only way to switch to a proper fullscreen mode is via some button of one&#39;s own making. Is that right ?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (William Labbett)</author>
		<pubDate>Tue, 03 May 2011 03:22:57 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Or a key shortcut.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Tue, 03 May 2011 03:24:36 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Without some kind of hacks like checking the new screen size is the full screen (with decorations), I think that&#39;s right.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Trent Gamblin)</author>
		<pubDate>Tue, 03 May 2011 03:24:38 +0000</pubDate>
	</item>
</rss>
