Class: Qt::Time

Inherits:
Base show all
Defined in:
lib/qt/qtruby4.rb

Instance Method Summary collapse

Methods inherited from Base

#%, #&, #*, #**, #+, #-, #-@, #/, #<, #<<, #<=, #==, #>, #>=, #>>, #^, #methods, #protected_methods, #public_methods, q_classinfo, q_signal, q_slot, signals, #singleton_methods, slots, #|, #~

Constructor Details

#initialize(*args) ⇒ Time

Returns a new instance of Time.



1549
1550
1551
1552
1553
1554
1555
# File 'lib/qt/qtruby4.rb', line 1549

def initialize(*args)
	if args.size == 1 && args[0].class.name == "Time"
		return super(args[0].hour, args[0].min, args[0].sec)
	else
		return super(*args)
	end
end

Instance Method Details

#inspectObject



1557
1558
1559
1560
# File 'lib/qt/qtruby4.rb', line 1557

def inspect
	str = super
	str.sub(/>$/, " %s>" % toString)
end

#pretty_print(pp) ⇒ Object



1562
1563
1564
1565
# File 'lib/qt/qtruby4.rb', line 1562

def pretty_print(pp)
	str = to_s
	pp.text str.sub(/>$/, " %s>" % toString)
end