ruby-x11/lib/X11/protocol.rb

17 lines
294 B
Ruby
Raw Normal View History

2011-08-01 06:51:22 +02:00
module X11
module Protocol
2011-08-01 06:51:22 +02:00
# endiness of your machine
BYTE_ORDER = case [1].pack("L")
when "\0\0\0\1"
"B".ord
2011-08-01 06:51:22 +02:00
when "\1\0\0\0"
"l".ord
2011-08-01 06:51:22 +02:00
else
raise ByteOrderError.new "Cannot determine byte order"
2011-08-01 06:51:22 +02:00
end
MAJOR = 11
MINOR = 0
end
end