Sha256: 06a7d9fe77dde33359f81183c461bf95c57747183f168c91f39478b628cfefa8

Contents?: true

Size: 756 Bytes

Versions: 7

Compression:

Stored size: 756 Bytes

Contents

# Copyright (c) 2023 M.J.N. Corino, The Netherlands
#
# This software is released under the MIT license.

# Wx::PG property (and related) classes

module Wx::PG

  class SystemColourProperty < EnumProperty

    # add some 'smart' conversions
    wx_initialize = instance_method :initialize
    define_method :initialize do |label=Wx::PG_LABEL, name=Wx::PG_LABEL, value=Wx::PG::ColourPropertyValue.new|
      value = case value
              when Wx::Colour
                Wx::PG::ColourPropertyValue.new(value)
              when Integer
                Wx::PG::ColourPropertyValue.new(value)
              else
                value
              end
      wx_initialize.bind(self).call(label, name, value)
    end

  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
wxruby3-0.9.7-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.5-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.4-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.3-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.2-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.1-x64-mingw-ucrt lib/wx/pg/pg_properties.rb
wxruby3-0.9.0-x64-mingw-ucrt lib/wx/pg/pg_properties.rb