Skip to content

Instantly share code, notes, and snippets.

@kattrali
Created January 17, 2011 16:21
Show Gist options
  • Save kattrali/783043 to your computer and use it in GitHub Desktop.
Save kattrali/783043 to your computer and use it in GitHub Desktop.
module Redcar
class REPL
class Tab < Redcar::EditTab
...
def update_cursor_size
if widget = edit_view.controller.mate_text.get_text_widget
caret = Swt::Widgets::Caret.new(widget, Swt::SWT::NONE)
caret.set_image(nil)
widget.set_caret(caret)
height = widget.get_line_height
width = edit_view.controller.char_width
caret.set_size(width,height)
caret.set_visible(true)
end
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment