Sha256: a527695306fcb8c71903ca3f93177c8829ff934ba1c521d6143adf0fce513da1
Contents?: true
Size: 763 Bytes
Versions: 21
Compression:
Stored size: 763 Bytes
Contents
module ZTK module GoogleChart class Base module Options def options=(value) set_options(value) end def options(value=nil) set_options(value) end private def default_width 900 end def set_options(value=nil) if @chart_options.nil? @chart_options = Hash.new @chart_options.merge!(:width => default_width.to_i, :height => default_width.div(2).to_i) end if !value.nil? && !value.empty? @chart_options.merge!(value) end config.ui.logger.info { "options(#{value.inspect}) -> #{@chart_options.inspect}" } @chart_options end end end end end
Version data entries
21 entries across 21 versions & 1 rubygems