Sha256: a4ba1d66f46441c2bc6e5ca4fa739889d7ed906e9b9f71c9dac0c6e8deb89eea
Contents?: true
Size: 501 Bytes
Versions: 1
Compression:
Stored size: 501 Bytes
Contents
require 'rubygems' require 'weskit' include Weskit::WML # Compared to builder example this one uses more # conservative approach to WML creation process. root = Root.new object = Element.new :object object << Attribute.new(:name, 'orb') object << Attribute.new(:type, 'magic item') modificationno = Element.new :modification modification << Attribute.new(:hp, 100) object << modification root << object # Set differend formatter globally. Formatter.default = Formatter.color puts root.to_s
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
weskit-0.3.1 | examples/formatter.rb |