Sha256: 54c2b85234186c8bea7c8c6fde912568dbba8835fff8f9b8c27311cb0ce0ad40
Contents?: true
Size: 867 Bytes
Versions: 4
Compression:
Stored size: 867 Bytes
Contents
# frozen_string_literal: true class Shoes module Swt class TextBlock class Painter include ::Swt::Events::PaintListener include Common::Resource attr_reader :app def initialize(dsl) @dsl = dsl end def paintControl(paint_event) # See #636 for discussion, contents_alignment may not run or if the # space is very narrow we might squish things down to be very narrow. # If paint is triggered then, code later on will crash. return if @dsl.hidden? || @dsl.gui.segments.nil? || @dsl.gui.segments.empty? reset_graphics_context(paint_event.gc) clip_context_to(paint_event.gc, @dsl.parent) do |gc| @dsl.gui.segments.paint_control(gc) end end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems