class Reline::LineEditor::DialogProcScope

Constants

CompletionJourneyData

Public Class Methods

new(line_editor, config, proc_to_exec, context) click to toggle source
# File reline/line_editor.rb, line 574
def initialize(line_editor, config, proc_to_exec, context)
  @line_editor = line_editor
  @config = config
  @proc_to_exec = proc_to_exec
  @context = context
  @cursor_pos = Reline::CursorPos.new
end

Public Instance Methods

call() click to toggle source
# File reline/line_editor.rb, line 644
def call
  instance_exec(&@proc_to_exec)
end
call_completion_proc_with_checking_args(pre, target, post) click to toggle source
# File reline/line_editor.rb, line 590
def call_completion_proc_with_checking_args(pre, target, post)
  @line_editor.call_completion_proc_with_checking_args(pre, target, post)
end
completion_journey_data() click to toggle source
# File reline/line_editor.rb, line 636
def completion_journey_data
  @line_editor.dialog_proc_scope_completion_journey_data
end
config() click to toggle source
# File reline/line_editor.rb, line 640
def config
  @config
end
context() click to toggle source
# File reline/line_editor.rb, line 582
def context
  @context
end
cursor_pos() click to toggle source
# File reline/line_editor.rb, line 615
def cursor_pos
  @cursor_pos
end
dialog() click to toggle source
# File reline/line_editor.rb, line 598
def dialog
  @dialog
end
just_cursor_moving() click to toggle source
# File reline/line_editor.rb, line 619
def just_cursor_moving
  @line_editor.instance_variable_get(:@just_cursor_moving)
end
key() click to toggle source
# File reline/line_editor.rb, line 611
def key
  @key
end
preferred_dialog_height() click to toggle source
# File reline/line_editor.rb, line 631
def preferred_dialog_height
  _wrapped_cursor_x, wrapped_cursor_y = @line_editor.wrapped_cursor_position
  [@line_editor.upper_space_height(wrapped_cursor_y), @line_editor.rest_height(wrapped_cursor_y), (screen_height + 6) / 5].max
end
retrieve_completion_block(set_completion_quote_character = false) click to toggle source
# File reline/line_editor.rb, line 586
def retrieve_completion_block(set_completion_quote_character = false)
  @line_editor.retrieve_completion_block(set_completion_quote_character)
end
screen_height() click to toggle source
# File reline/line_editor.rb, line 627
def screen_height
  @line_editor.screen_height
end
screen_width() click to toggle source
# File reline/line_editor.rb, line 623
def screen_width
  @line_editor.screen_width
end
set_cursor_pos(col, row) click to toggle source
# File reline/line_editor.rb, line 602
def set_cursor_pos(col, row)
  @cursor_pos.x = col
  @cursor_pos.y = row
end
set_dialog(dialog) click to toggle source
# File reline/line_editor.rb, line 594
def set_dialog(dialog)
  @dialog = dialog
end
set_key(key) click to toggle source
# File reline/line_editor.rb, line 607
def set_key(key)
  @key = key
end