The Birdfont Source Code


All Repositories / birdfont.git / commit – RSS feed

Spelling

These changes was commited to the Birdfont repository Mon, 24 Aug 2015 13:40:37 +0000.

Contributing

Send patches or pull requests to johan.mattsson.m@gmail.com.
Clone this repository: git clone https://github.com/johanmattssonm/birdfont.git
author Johan Mattsson <johan.mattsson.m@gmail.com>
Mon, 24 Aug 2015 13:40:37 +0000 (15:40 +0200)
committer Johan Mattsson <johan.mattsson.m@gmail.com>
Mon, 24 Aug 2015 13:53:49 +0000 (15:53 +0200)
commit 2d02a0307d0d118c95dd244d59981f8474830d41
tree f95cef899fa7ab150e987aab8b2a4e9cb8290e67
parent 6e6045de9d708c58241833a21720e7de28cd4364
Spelling

libbirdfont/OpenFontFormat/DirectoryTable.vala
libbirdfont/OpenFontFormat/FontData.vala
libbirdfont/OpenFontFormat/HeadTable.vala
libbirdfont/TestBirdFont.vala
--- a/libbirdfont/OpenFontFormat/DirectoryTable.vala +++ b/libbirdfont/OpenFontFormat/DirectoryTable.vala @@ -386,7 +386,7 @@ dis.write_at (p + 2, 0); dis.write_at (p + 3, 0); - checksum_font = (uint32) (0xB1B0AFBA - dis.check_sum ()); + checksum_font = (uint32) (0xB1B0AFBA - dis.checksum ()); if (checksum_font != checksum_head) { warning (@"Fontfile checksum in head table does not match calculated checksum. checksum_font: $checksum_font checksum_head: $checksum_head"); @@ -413,11 +413,11 @@ // Check sum adjustment for the entire font public uint32 get_font_file_checksum () { - uint32 check_sum = 0; + uint32 checksum = 0; foreach (OtfTable t in tables) { - t.get_font_data ().continous_check_sum (ref check_sum); + t.get_font_data ().continous_checksum (ref checksum); } - return check_sum; + return checksum; } public void create_directory () throws GLib.Error { @@ -426,7 +426,7 @@ uint32 table_offset = 0; uint32 table_length = 0; - uint32 check_sum = 0; + uint32 checksum = 0; fd = new FontData (); @@ -438,7 +438,7 @@ table_offset += this.get_font_data ().length_with_padding (); } - head_table.set_check_sum_adjustment (0); // Set this to zero, calculate checksums and update the value + head_table.set_checksum_adjustment (0); // Set this to zero, calculate checksums and update the value head_table.process (); // write the directory @@ -453,7 +453,7 @@ table_length = t.get_font_data ().length (); // without padding fd.add_tag (t.get_id ()); // name of table - fd.add_u32 (t.get_font_data ().check_sum ()); + fd.add_u32 (t.get_font_data ().checksum ()); fd.add_u32 (table_offset); fd.add_u32 (table_length); @@ -465,8 +465,8 @@ this.font_data = fd; - check_sum = get_font_file_checksum (); - head_table.set_check_sum_adjustment ((uint32)(0xB1B0AFBA - check_sum)); + checksum = get_font_file_checksum (); + head_table.set_checksum_adjustment ((uint32)(0xB1B0AFBA - checksum)); head_table.process (); // update the value }
--- a/libbirdfont/OpenFontFormat/FontData.vala +++ b/libbirdfont/OpenFontFormat/FontData.vala @@ -97,7 +97,7 @@ } /** Add additional checksum data to this checksum. */ - public void continous_check_sum (ref uint32 current_check_sum) { + public void continous_checksum (ref uint32 current_checksum) { uint trp = rp; uint l; @@ -110,7 +110,7 @@ l = (length () % 4 > 0) ? length () / 4 + 1 : length () / 4; for (uint32 i = 0; i < l; i++) { - current_check_sum += read_uint32 (); + current_checksum += read_uint32 (); } rp = trp; @@ -118,9 +118,9 @@ return; } - public uint32 check_sum () { + public uint32 checksum () { uint32 sum = 0; - continous_check_sum (ref sum); + continous_checksum (ref sum); return sum; }
--- a/libbirdfont/OpenFontFormat/HeadTable.vala +++ b/libbirdfont/OpenFontFormat/HeadTable.vala @@ -154,7 +154,7 @@ return adjusted_checksum; } - public void set_check_sum_adjustment (uint32 csa) { + public void set_checksum_adjustment (uint32 csa) { this.adjusted_checksum = csa; }
--- a/libbirdfont/TestBirdFont.vala +++ b/libbirdfont/TestBirdFont.vala @@ -92,7 +92,7 @@ if (!has_test_case (st)) { stderr.printf (@"Test case \"$st\" does not exist.\n"); - stderr.printf ("\nAvaliable test cases:\n"); + stderr.printf ("\nAvailable test cases:\n"); foreach (var t in test_cases) { stderr.printf (t.name);