Permalink
Commits on Feb 20, 2011
Commits on Feb 19, 2011
  1. Renamed get_key_state to pressed_keys, and improved it.

    * Runs SDL.PumpEvents() to ensure key state is up to date.
    
    * The returned hash only has the keys that are pressed, non-pressed
      keys are omitted (instead of set to false). This is more
      lightweight, and easier to convert to a plain Array of the keys that
      are pressed.
    
    * Simplified code.
    
    * Rewrote docs.
    jacius committed Feb 19, 2011
  2. Moved Rubygame.get_key_state from main.rb to events.rb.

    Also cleaned up credits/copyright info.
    jacius committed Feb 19, 2011
  3. Fixed Surface#flatten specs failing on Ruby 1.8.

    Problem was a name collision with the "args" block arg.
    jacius committed Feb 19, 2011
  4. Surface methods can accept hex color string for colors.

    Leading "#" is required, to disambiguate from a color name.
    If the hex color string is also an existing color name,
    the name takes precedence.
    jacius committed Feb 18, 2011
Commits on Feb 18, 2011
  1. Minor ImageFont docs tweaks.

    jacius committed Feb 18, 2011
  2. Revamped ImageFont so that glyph strings can be any length.

    This allows multi-byte chars on Ruby 1.8, ligatures, emoticons, etc.
    jacius committed Feb 16, 2011
  3. Added Rubygame::ImageFont class, with a nifty demo.

    Intended as a replacement for Rubygame::SFont, which will be removed
    in Rubygame 3.0.
    jacius committed Feb 14, 2011
Commits on Feb 12, 2011
  1. Fixed some issues with the old Rect class.

    Rect#size would return a Rect with only 2 elements, which would break
    Rect#to_s, Rect#inspect, and most methods that received the malformed
    Rect (e.g. Surface#blit).
    jacius committed Feb 12, 2011
Commits on Feb 11, 2011
  1. Added Surface#to_opengl method.

    Returns a hash with pixel data and format information that
    you can use to create an OpenGL texture from this Surface.
    jacius committed Feb 11, 2011
Commits on Feb 9, 2011
  1. Surface.new raises TypeError on bad size or depth.

    (Instead of ArgumentError.)
    jacius committed Feb 9, 2011
Commits on Feb 8, 2011
  1. Revamped Rubygame deprecation warnings.

    Its behavior is influenced by the value of ENV["RUBYGAME_DEPRECATED"]:
    
    * (default): Print a warning with Kernel.warn the first time
                 each deprecated feature is used. Note that Kernel.warn
                 is silent unless warnings are enabled (e.g. -W flag).
    
    * "warn":    Print a warning on STDERR the first time each deprecated
                 feature is used.
    
    * "warn!":   Print a warning on STDERR every time a deprecated
                 feature is used.
    
    * "error":   Raise Rubygame::DeprecationError the first time each
                 deprecated feature is used.
    
    * "error!":  Raise Rubygame::DeprecationError every time a
                 deprecated feature is used.
    
    * "quiet":   Never warn when any deprecated feature is used.
    jacius committed Feb 8, 2011
  2. Revamped Surface#colorkey and #colorkey=.

    * Surface#colorkey now sets the colorkey when given an arg.
    * The 'flags' arg to Surface#colorkey= is now DEPRECATED.
    * Surface#set_colorkey is now DEPRECATED.
    jacius committed Feb 8, 2011
  3. Typo in Surface#opacity docs.

    jacius committed Feb 7, 2011
Commits on Feb 7, 2011