Class: Shoes::Swt::TextBlockPainter
- Inherits:
-
Object
- Object
- Shoes::Swt::TextBlockPainter
- Defined in:
- lib/pirate_game/shoes4_patch.rb
Instance Method Summary collapse
-
#paintControl(paint_event) ⇒ Object
added the return statement on line 8.
Instance Method Details
#paintControl(paint_event) ⇒ Object
added the return statement on line 8
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/pirate_game/shoes4_patch.rb', line 12 def paintControl(paint_event) graphics_context = paint_event.gc gcs_reset graphics_context @text_layout.setText @dsl.text set_styles if @dsl.width @text_layout.setWidth @dsl.width return if @dsl.absolute_left.nil? || @dsl.margin_left.nil? || @dsl.absolute_top.nil? || @dsl.margin_top.nil? @text_layout.draw graphics_context, @dsl.absolute_left + @dsl.margin_left, @dsl.absolute_top + @dsl.margin_top if @dsl.cursor move_text_cursor else (@dsl.textcursor.remove; @dsl.textcursor = nil) if @dsl.textcursor end end end |