Sha256: 6e4f996a27304c26583c599f7de060034541bf3b64ba04b47d60cf1d9b40939d

Contents?: true

Size: 615 Bytes

Versions: 5

Compression:

Stored size: 615 Bytes

Contents

require 'fox16'

include Fox

class RulerViewExample < FXMainWindow
  def initialize(app)
    # Initialize base class
    super(app, "Ruler View", nil, nil, DECOR_ALL, 0, 0, 400, 400)
    
    # Construct a ruler view inside
    ruler_view = FXRulerView.new(self, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y)
    
    # And put some content inside that
    contents = FXText.new(ruler_view, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y)
    contents.text = "This is a test."
  end
end

if __FILE__ == $0
  FXApp.new do |app|
    main = RulerViewExample.new(app)
    app.create
    main.show(PLACEMENT_SCREEN)
    app.run
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
fxruby-1.6.1 examples/rulerview.rb
fxruby-1.6.2 examples/rulerview.rb
fxruby-1.6.3 examples/rulerview.rb
fxruby-1.6.4 examples/rulerview.rb
fxruby-1.6.5 examples/rulerview.rb