Module: Rumai
- Extended by:
- Rumai
- Includes:
- ClientContainer
- Included in:
- Rumai
- Defined in:
- lib/rumai/ixp/message.rb,
lib/rumai/fs.rb,
lib/rumai/wm.rb,
lib/rumai/inochi.rb,
lib/rumai/ixp/transport.rb
Overview
Primitives for the 9P2000 protocol.
See cm.bell-labs.com/sys/man/5/INDEX.html See swtch.com/plan9port/man/man9/
Defined Under Namespace
Modules: Chain, ClientContainer, ExportInstanceMethods, IXP, WidgetImpl Classes: Area, Barlet, Client, Node, View, WidgetNode
Constant Summary collapse
- IXP_SOCK_ADDR =
ENV['WMII_ADDRESS'].sub(/.*!/, '') rescue "/tmp/ns.#{ENV['USER']}.#{display[/:\d+/]}/wmii"
- IXP_FS_ROOT =
Node.new('/')
- FOCUSED_WIDGET_ID =
'sel'.freeze
- FLOATING_AREA_ID =
'~'.freeze
- CLIENT_GROUPING_TAG =
'@'.freeze
- CLIENT_STICKY_TAG =
'/./'.freeze
- PROJECT =
Official name of this project.
'Rumai'
- TAGLINE =
Short single-line description of this project.
'Ruby interface to the wmii window manager'
- WEBSITE =
Address of this project’s official home page.
'http://snk.tuxfamily.org/lib/rumai/'
- VERSION =
Number of this release of this project.
'4.1.3'
- RELDATE =
Date of this release of this project.
'2011-08-21'
- INSTDIR =
Location of this release of this project.
File.('../../..', __FILE__)
- GEMDEPS =
RubyGems required by this project during runtime.
{}
Class Method Summary collapse
-
.inspect ⇒ Object
Description of this release of this project.
Instance Method Summary collapse
-
#client_ids ⇒ Object
Returns the IDs of the current set of clients.
- #curr_area ⇒ Object
-
#curr_client ⇒ Object
————————————————————————— shortcuts for interactive WM manipulation (via IRB) —————————————————————————.
- #curr_tag ⇒ Object
- #curr_view ⇒ Object
- #focus_area(id) ⇒ Object
- #focus_client(id) ⇒ Object
- #focus_view(id) ⇒ Object
-
#fs ⇒ Object
Returns the root of IXP file system hierarchy.
-
#grouping ⇒ Object
Returns a list of all grouped clients in the currently focused view.
- #next_area ⇒ Object
- #next_client ⇒ Object
- #next_tag ⇒ Object
- #next_view ⇒ Object
- #prev_area ⇒ Object
- #prev_client ⇒ Object
- #prev_tag ⇒ Object
- #prev_view ⇒ Object
-
#tags ⇒ Object
Returns the current set of tags.
-
#views ⇒ Object
Returns the current set of views.
Methods included from ClientContainer
Class Method Details
Instance Method Details
#client_ids ⇒ Object
Returns the IDs of the current set of clients.
1215 1216 1217 1218 1219 |
# File 'lib/rumai/wm.rb', line 1215 def client_ids ary = IXP_FS_ROOT.client.entries ary.delete FOCUSED_WIDGET_ID ary end |
#curr_client ⇒ Object
shortcuts for interactive WM manipulation (via IRB)
1225 |
# File 'lib/rumai/wm.rb', line 1225 def curr_client ; Client.curr ; end |
#curr_tag ⇒ Object
1237 |
# File 'lib/rumai/wm.rb', line 1237 def curr_tag ; curr_view.id ; end |
#focus_area(id) ⇒ Object
1248 1249 1250 |
# File 'lib/rumai/wm.rb', line 1248 def focus_area id Area.focus id end |
#focus_client(id) ⇒ Object
1244 1245 1246 |
# File 'lib/rumai/wm.rb', line 1244 def focus_client id Client.focus id end |
#focus_view(id) ⇒ Object
1252 1253 1254 |
# File 'lib/rumai/wm.rb', line 1252 def focus_view id View.focus id end |
#fs ⇒ Object
Returns the root of IXP file system hierarchy.
1176 1177 1178 |
# File 'lib/rumai/wm.rb', line 1176 def fs IXP_FS_ROOT end |
#grouping ⇒ Object
Returns a list of all grouped clients in the currently focused view. If there are no grouped clients, then the currently focused client is returned in the list.
1202 1203 1204 1205 1206 |
# File 'lib/rumai/wm.rb', line 1202 def grouping list = curr_view.clients.select {|c| c.group? } list << curr_client if list.empty? and curr_client.exist? list end |
#next_area ⇒ Object
1230 |
# File 'lib/rumai/wm.rb', line 1230 def next_area ; curr_area.next ; end |
#next_client ⇒ Object
1226 |
# File 'lib/rumai/wm.rb', line 1226 def next_client ; curr_client.next ; end |
#next_tag ⇒ Object
1238 |
# File 'lib/rumai/wm.rb', line 1238 def next_tag ; next_view.id ; end |
#next_view ⇒ Object
1234 |
# File 'lib/rumai/wm.rb', line 1234 def next_view ; curr_view.next ; end |
#prev_area ⇒ Object
1231 |
# File 'lib/rumai/wm.rb', line 1231 def prev_area ; curr_area.prev ; end |
#prev_client ⇒ Object
1227 |
# File 'lib/rumai/wm.rb', line 1227 def prev_client ; curr_client.prev ; end |
#prev_tag ⇒ Object
1239 |
# File 'lib/rumai/wm.rb', line 1239 def prev_tag ; prev_view.id ; end |
#prev_view ⇒ Object
1235 |
# File 'lib/rumai/wm.rb', line 1235 def prev_view ; curr_view.prev ; end |
#tags ⇒ Object
Returns the current set of tags.
1183 1184 1185 1186 1187 |
# File 'lib/rumai/wm.rb', line 1183 def ary = IXP_FS_ROOT.tag.entries.sort ary.delete FOCUSED_WIDGET_ID ary end |