Method: TkPhotoImage#put

Defined in:
lib/tk/image.rb

#put(data, *opts) ⇒ Object



330
331
332
333
334
335
336
337
338
339
340
# File 'lib/tk/image.rb', line 330

def put(data, *opts)
  if opts.empty?
    tk_send('put', data)
  elsif opts.size == 1 && opts[0].kind_of?(Hash)
    tk_send('put', data, *_photo_hash_kv(opts[0]))
  else
    # for backward compatibility
    tk_send('put', data, '-to', *opts)
  end
  self
end