Skip to content

Commit fc56a85

Browse files
committed
core-graphics: Implement CTFontGetMatrix.
1 parent dec5ede commit fc56a85

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

core-text/src/font.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -494,6 +494,12 @@ impl CTFont {
494494
}
495495
}
496496

497+
pub fn get_matrix(&self) -> CGAffineTransform {
498+
unsafe {
499+
CTFontGetMatrix(self.as_concrete_TypeRef())
500+
}
501+
}
502+
497503
pub fn url(&self) -> Option<CFURL> {
498504
unsafe {
499505
let result = CTFontCopyAttribute(self.0, kCTFontURLAttribute);
@@ -692,7 +698,7 @@ extern "C" {
692698
fn CTFontCopyFontDescriptor(font: CTFontRef) -> CTFontDescriptorRef;
693699
fn CTFontCopyAttribute(font: CTFontRef, attribute: CFStringRef) -> CFTypeRef;
694700
fn CTFontGetSize(font: CTFontRef) -> CGFloat;
695-
//fn CTFontGetMatrix
701+
fn CTFontGetMatrix(font: CTFontRef) -> CGAffineTransform;
696702
fn CTFontGetSymbolicTraits(font: CTFontRef) -> CTFontSymbolicTraits;
697703
fn CTFontCopyTraits(font: CTFontRef) -> CFDictionaryRef;
698704

0 commit comments

Comments
 (0)