clarify naming convention

This commit is contained in:
Qwerasd
2024-12-12 20:38:26 -05:00
parent 0557bf8301
commit 0a29b78a6c
4 changed files with 10 additions and 0 deletions

View File

@ -6,6 +6,8 @@ const sfnt = @import("sfnt.zig");
/// ///
/// References: /// References:
/// - https://learn.microsoft.com/en-us/typography/opentype/spec/head /// - https://learn.microsoft.com/en-us/typography/opentype/spec/head
///
/// Field names are in camelCase to match names in spec.
pub const Head = extern struct { pub const Head = extern struct {
/// Major version number of the font header table set to 1. /// Major version number of the font header table set to 1.
majorVersion: sfnt.uint16 align(1), majorVersion: sfnt.uint16 align(1),

View File

@ -6,6 +6,8 @@ const sfnt = @import("sfnt.zig");
/// ///
/// References: /// References:
/// - https://learn.microsoft.com/en-us/typography/opentype/spec/hhea /// - https://learn.microsoft.com/en-us/typography/opentype/spec/hhea
///
/// Field names are in camelCase to match names in spec.
pub const Hhea = extern struct { pub const Hhea = extern struct {
/// Major version number of the horizontal header table set to 1. /// Major version number of the horizontal header table set to 1.
majorVersion: sfnt.uint16 align(1), majorVersion: sfnt.uint16 align(1),

View File

@ -43,6 +43,8 @@ pub const FSSelection = packed struct(sfnt.uint16) {
/// ///
/// References: /// References:
/// - https://learn.microsoft.com/en-us/typography/opentype/spec/os2 /// - https://learn.microsoft.com/en-us/typography/opentype/spec/os2
///
/// Field names are in camelCase to match names in spec.
pub const OS2v5 = extern struct { pub const OS2v5 = extern struct {
version: sfnt.uint16 align(1), version: sfnt.uint16 align(1),
xAvgCharWidth: sfnt.FWORD align(1), xAvgCharWidth: sfnt.FWORD align(1),
@ -198,6 +200,8 @@ pub const OS2v0 = extern struct {
/// ///
/// References: /// References:
/// - https://learn.microsoft.com/en-us/typography/opentype/spec/os2 /// - https://learn.microsoft.com/en-us/typography/opentype/spec/os2
///
/// Field names are in camelCase to match names in spec.
pub const OS2 = struct { pub const OS2 = struct {
/// The version number for the OS/2 table: 0x0000 to 0x0005. /// The version number for the OS/2 table: 0x0000 to 0x0005.
/// ///

View File

@ -9,6 +9,8 @@ const sfnt = @import("sfnt.zig");
/// ///
/// References: /// References:
/// - https://learn.microsoft.com/en-us/typography/opentype/spec/post /// - https://learn.microsoft.com/en-us/typography/opentype/spec/post
///
/// Field names are in camelCase to match names in spec.
pub const Post = extern struct { pub const Post = extern struct {
version: sfnt.Version16Dot16 align(1), version: sfnt.Version16Dot16 align(1),