######## libxosd-ruby ########

1. Introduction
2. Compiling
3. Installing
4. Example
5. Contact
  1. Introduction

XOSD is a system that displays text on top of the other windows, much like the on-screen display (OSD) used by most modern televisions and video-players. libxosd-ruby is a ruby interface to this library.

BUGS:

Since XOSD uses pthread, and (at least in Debian) ruby is, by default, compiled without -lpthread, the ruby process sometimes fails to exit when XOSD is used, unless “exit!” is used. This library checks if ruby was compiled with “-lpthread”, and if not, adds an exit handler using “at_exit” that executes “exit!”.

  1. Compiling:

$ ruby extconf.rb (if this fails looking for 'mkmf', you probably need the ruby-dev package) $ make

  1. Installing:

Installation may need to be done as root. Installs to ruby site dir.

$ ruby install.rb

  1. Example

require 'rxosd' osd = RXOSD.new(2) osd.font = '---bold-r---33---*----' osd.align = RXOSD::LEFT osd.valign = RXOSD::BOTTOM osd.timeout = 4 osd.puts(“First line”) sleep 1 osd.puts(“Second line”) sleep 1 osd.puts(“First line again”, 0) sleep 1 osd.slider(50, 1) osd.wait_until_hidden osd.clear osd.timeout = 4 osd.puts(“Second line again”, 1)

  1. Contact:

If you have any problems, comments, or questions, please contact me one of the following ways: Email: Derek Lewis <[email protected]> Bug Reports: rubyforge.org/tracker/?atid=595&group_id=133 Feature Requests: rubyforge.org/tracker/?atid=598&group_id=133 Support Requests: rubyforge.org/tracker/?atid=596&group_id=133 Open Discussion: rubyforge.org/forum/forum.php?forum_id=537