Commits

illume committed bccb34d

new docs because of scrap.

Comments (0)

Files changed (23)

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/cursors.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/display.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <li><a href="rect.html#Rect.unionall">Rect.unionall</a> - <font size=-1>the union of many rectangles</font></li>
 <li><a href="rect.html#Rect.unionall_ip">Rect.unionall_ip</a> - <font size=-1>the union of many rectangles, in place</font></li>
 </ul>
+<li><a href="scrap.html#pygame.scrap">pygame.scrap</a> - <font size=-1></font></li>
+<ul>
+<li></li>
+<li><a href="scrap.html#pygame.scrap.get">pygame.scrap.get</a> - <font size=-1>Gets stuff from the clipboard.</font></li>
+<li><a href="scrap.html#pygame.scrap.init">pygame.scrap.init</a> - <font size=-1>raises an error on error.</font></li>
+<li><a href="scrap.html#pygame.scrap.lost">pygame.scrap.lost</a> - <font size=-1>Has the clipboard contents been lost.</font></li>
+<li><a href="scrap.html#pygame.scrap.put">pygame.scrap.put</a> - <font size=-1>Puts stuff into the clipboard.</font></li>
+</ul>
 <li><a href="sndarray.html#pygame.sndarray">pygame.sndarray</a> - <font size=-1>pygame module for accessing sound sample data</font></li>
 <ul>
 <li><a href="sndarray.html#pygame.sndarray.array">pygame.sndarray.array</a> - <font size=-1>copy Sound samples into an array</font></li>
 <li><a href="time.html#Clock.get_rawtime">Clock.get_rawtime</a> - <font size=-1>actual time used in the previous tick</font></li>
 <li><a href="time.html#Clock.get_time">Clock.get_time</a> - <font size=-1>time used in the previous tick</font></li>
 <li><a href="time.html#Clock.tick">Clock.tick</a> - <font size=-1>update the clock</font></li>
+<li><a href="time.html#Clock.tick_busy_loop">Clock.tick_busy_loop</a> - <font size=-1>update the clock</font></li>
 </ul>
 <li><a href="time.html#pygame.time.delay">pygame.time.delay</a> - <font size=-1>pause the program for an amount of time</font></li>
 <li><a href="time.html#pygame.time.get_ticks">pygame.time.get_ticks</a> - <font size=-1>get the time in milliseconds</font></li>

docs/ref/joystick.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
   <tt>pygame.mixer.init(frequency=22050, size=-16, stereo=True, buffer=1024): return None</tt><br>
 <p>Initialize the mixer module for Sound loading and playback. The default arguments can be overridden to provide specific audio mixing. The size argument represents how many bits are used for each audio sample. If the value is negative then signed sample values will be used. Positive values mean unsigned audio samples will be used. If the stereo argument is false the mixer will use mono sound. </p>
 <p>The buffer argument controls the number of internal samples used in the sound mixer. The default value should work for most cases. It can be lowered to reduce latency, but sound dropout may occur. It can be raised to larger values to ensure playback never skips, but it will impose latency on sound playback. The buffer size must be a power of two. </p>
-<p>Some platforms require the <tt>pygame.mixer</tt> module to be required after the display modules have initialized. The top level <tt><a href="pygame.html#pygame.init">pygame.init</a> - <font size=-1>initialize all imported pygame modules</font></tt> takes care of this automatically, but cannot pass any arguments to the mixer init. To solve this, mixer has a function <tt><a href="mixer.html#pygame.mixer.pre_init">pygame.mixer.pre_init</a> - <font size=-1>preset the mixer init arguments</font></tt> to set the proper defaults before the toplevel init is used. </p>
+<p>Some platforms require the <tt>pygame.mixer</tt> module to be initialized after the display modules have initialized. The top level <tt><a href="pygame.html#pygame.init">pygame.init</a> - <font size=-1>initialize all imported pygame modules</font></tt> takes care of this automatically, but cannot pass any arguments to the mixer init. To solve this, mixer has a function <tt><a href="mixer.html#pygame.mixer.pre_init">pygame.mixer.pre_init</a> - <font size=-1>preset the mixer init arguments</font></tt> to set the proper defaults before the toplevel init is used. </p>
 <p>It is safe to call this more than once, but after the mixer is initialized you cannot change the playback arguments without first calling <tt><a href="mixer.html#pygame.mixer.quit">pygame.mixer.quit</a> - <font size=-1>uninitialize the mixer</font></tt>. </p>
 <!--COMMENTS:pygame.mixer.init--> &nbsp;<br> 
 <br></ul>
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/overlay.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
   <i>initialize all imported pygame modules</i><br>
   <tt>pygame.init(): return (numpass, numfail)</tt><br>
 <p>Initialize all imported Pygame modules. No exceptions will be raised if a module fails, but the total number if successful and failed inits will be returned as a tuple. You can always initialize individual modules manually, but <tt>pygame.init</tt> is a convenient way to get everything started. The init() functions for individual modules will raise exceptions when they fail. </p>
+<p>You may want to initalise the different modules seperately to speed up your program or to not use things your game does not. </p>
 <p>It is safe to call this init() more than once: repeated calls will have no effect. This is true even if you have <tt><a href="pygame.html#pygame.quit">pygame.quit</a> - <font size=-1>uninitialize all pygame modules</font></tt> all the modules. </p>
 <!--COMMENTS:pygame.init--> &nbsp;<br> 
 <br></ul>
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/sndarray.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/surface.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;

docs/ref/surfarray.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;
   <tt>pygame.time.Clock(): return Clock</tt><br>
 <ul><small><table>
   <tr><td><a href="time.html#Clock.tick">Clock.tick</a> - <font size=-1>update the clock</font></td><td>update the clock</td></tr>
+  <tr><td><a href="time.html#Clock.tick_busy_loop">Clock.tick_busy_loop</a> - <font size=-1>update the clock</font></td><td>update the clock</td></tr>
   <tr><td><a href="time.html#Clock.get_time">Clock.get_time</a> - <font size=-1>time used in the previous tick</font></td><td>time used in the previous tick</td></tr>
   <tr><td><a href="time.html#Clock.get_rawtime">Clock.get_rawtime</a> - <font size=-1>actual time used in the previous tick</font></td><td>actual time used in the previous tick</td></tr>
   <tr><td><a href="time.html#Clock.get_fps">Clock.get_fps</a> - <font size=-1>compute the clock framerate</font></td><td>compute the clock framerate</td></tr>
   <tt>control timer events</tt><br>
 <p>This method should be called once per frame. It will compute how many milliseconds have passed since the previous call. </p>
 <p>If you pass the optional framerate argument the function will delay to keep the game running slower than the given ticks per second. This can be used to help limit the runtime speed of a game. By calling <tt>Clock.tick(40)</tt> once per frame, the program will never run at more than 40 frames per second. </p>
+<p>Note that this function uses SDL_Delay function which is not accurate on every platform, but does not use much cpu. Use tick_busy_loop if you want an accurate timer, and don't mind chewing cpu. </p>
+<!--COMMENTS:Clock.tick--> &nbsp;<br> 
+<br></ul>
+
+
+<a name="Clock.tick_busy_loop">
+<big><b>Clock.tick_busy_loop</big></b><br><ul>
+  <i>update the clock</i><br>
+  <tt>Clock.tick_busy_loop([framerate]) -> milliseconds</tt><br>
+  <tt>control timer events</tt><br>
+<p>This method should be called once per frame. It will compute how many milliseconds have passed since the previous call. </p>
+<p>If you pass the optional framerate argument the function will delay to keep the game running slower than the given ticks per second. This can be used to help limit the runtime speed of a game. By calling <tt>Clock.tick(40)</tt> once per frame, the program will never run at more than 40 frames per second. </p>
 <p>Note that this function uses <tt>pygame.time.delay</tt>, which uses lots of cpu in a busy loop to make sure that timing is more acurate. </p>
-<!--COMMENTS:Clock.tick--> &nbsp;<br> 
+<!--COMMENTS:Clock.tick_busy_loop--> &nbsp;<br> 
 <br></ul>
 
 

docs/ref/transform.html

 <a href=overlay.html>Overlay</a>&nbsp;||&nbsp;
 <a href=pygame.html>Pygame</a>&nbsp;||&nbsp;
 <a href=rect.html>Rect</a>&nbsp;||&nbsp;
+<a href=scrap.html>Scrap</a>&nbsp;||&nbsp;
 <a href=sndarray.html>Sndarray</a>&nbsp;||&nbsp;
 <a href=sprite.html>Sprite</a>&nbsp;||&nbsp;
 <a href=surface.html>Surface</a>&nbsp;||&nbsp;