--- a/FontDescription.st Thu Nov 27 01:07:04 2014 +0100
+++ b/FontDescription.st Thu Nov 27 01:10:50 2014 +0100
@@ -1059,6 +1059,28 @@
^ self asStyle:#oblique
!
+asPixelSize:anotherSize
+ "return another font corresponding to the receivers family, face and style but
+ with another pixel size"
+
+ |newFont|
+
+ family isNil ifTrue:[
+ "CompoundFonts do not have a family"
+ ^ self
+ ].
+ newFont := self class
+ family:family
+ face:face
+ style:style
+ size:anotherSize
+ sizeUnit:#px
+ encoding:encoding.
+
+ newFont isGenericFont:self isGenericFont.
+ ^ newFont onDevice:self graphicsDevice.
+!
+
asSize:anotherSize
"return another font corresponding to the receivers family, face and style but
with another size"
@@ -1708,11 +1730,11 @@
!FontDescription class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview/FontDescription.st,v 1.96 2014-07-09 02:52:30 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/FontDescription.st,v 1.97 2014-11-27 00:10:50 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libview/FontDescription.st,v 1.96 2014-07-09 02:52:30 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview/FontDescription.st,v 1.97 2014-11-27 00:10:50 cg Exp $'
! !