Method: Tk::BLT::PlotComponent::Postscript.new
- Defined in:
- ext/lib/tkextlib/blt/component.rb
.new(chart, keys = {}) ⇒ Object
1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 |
# File 'ext/lib/tkextlib/blt/component.rb', line 1075 def self.new(chart, keys={}) obj = nil PostscriptID_TBL.mutex.synchronize{ unless (obj = PostscriptID_TBL[chart.path]) (obj = self.allocate).instance_eval{ @parent = @chart = chart @cpath = @chart.path @path = @id = 'postscript' Postscript::PostscriptID_TBL[@cpath] = self } end } chart.postscript_configure(keys) if obj && ! keys.empty? obj end |