Module: VER::Platform

Included in:
MajorMode, MinorMode
Defined in:
lib/ver/platform.rb

Class Method Summary collapse

Class Method Details

.aqua?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'lib/ver/platform.rb', line 13

def aqua?
  windowingsystem == :aqua
end

.bsd?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/ver/platform.rb', line 21

def bsd?
  FFI::Platform.bsd?
end

.mac?Boolean

Returns:

  • (Boolean)


29
30
31
# File 'lib/ver/platform.rb', line 29

def mac?
  FFI::Platform.mac?
end

.operatingsystemObject



37
38
39
# File 'lib/ver/platform.rb', line 37

def operatingsystem
  FFI::Platform::OS
end

.unix?Boolean

Returns:

  • (Boolean)


33
34
35
# File 'lib/ver/platform.rb', line 33

def unix?
  FFI::Platform.unix?
end

.win32?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/ver/platform.rb', line 9

def win32?
  windowingsystem == :win32
end

.windowingsystemObject



17
18
19
# File 'lib/ver/platform.rb', line 17

def windowingsystem
  @windowingsystem ||= Tk::TkCmd.windowingsystem
end

.windows?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'lib/ver/platform.rb', line 25

def windows?
  FFI::Platform.windows?
end

.x11?Boolean

Returns:

  • (Boolean)


5
6
7
# File 'lib/ver/platform.rb', line 5

def x11?
  windowingsystem == :x11
end