[cairo-commit] rcairo/src/lib cairo.rb,1.13,1.14

Kouhei Sutou commit at pdx.freedesktop.org
Thu Feb 21 05:17:50 PST 2008


Committed by: kou

Update of /cvs/cairo/rcairo/src/lib
In directory kemper:/tmp/cvs-serv1055/src/lib

Modified Files:
	cairo.rb 
Log Message:
* src/: supported <= 1.5.10.


Index: cairo.rb
===================================================================
RCS file: /cvs/cairo/rcairo/src/lib/cairo.rb,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- cairo.rb	11 Jan 2008 12:18:34 -0000	1.13
+++ cairo.rb	21 Feb 2008 13:18:11 -0000	1.14
@@ -53,11 +53,39 @@
     end
   end
 
-  class SVGSurface
-    class << self
-      def versions_as_string
-        versions.collect do |version|
-          version_to_string(version)
+  if const_defined?("PSLevel")
+    module PSLevel
+      class << self
+        def names
+          list.collect {|version| name(version)}
+        end
+      end
+    end
+  end
+
+  if const_defined?("SVGVersion")
+    module SVGVersion
+      class << self
+        def names
+          list.collect {|version| name(version)}
+        end
+      end
+    end
+  end
+
+  if const_defined?("SVGSurface")
+    class SVGSurface
+      class << self
+        def versions_as_string
+          SVGVersion.names
+        end
+
+        def versions
+          SVGVersion.list
+        end
+
+        def version_to_string(version)
+          SVGVersion.name(version)
         end
       end
     end



More information about the cairo-commit mailing list