Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1035)

Issue 6410047: OTS: Adds more layout common table supports.... (Closed)

Created:
9 years, 10 months ago by bashi
Modified:
9 years, 7 months ago
Reviewers:
Yusuke Sato, agl
CC:
chromium-reviews
Visibility:
Public.

Description

OTS: Adds more layout common table supports. Added Script table, Featre table, Lookup table, and Device table support. This is a part of adding GPOS/GSUB table support. The CL also contains unittests for layout common tables. Some fix for bugs which detected by the unittests also included. BUG=27131 TEST=test/layout_common_table_test.cc

Patch Set 1 #

Total comments: 10

Patch Set 2 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1190 lines, -4 lines) Patch
M include/ots-memory-stream.h View 1 2 chunks +3 lines, -3 lines 0 comments Download
M src/gdef.h View 1 chunk +7 lines, -0 lines 0 comments Download
M src/gdef.cc View 1 8 chunks +17 lines, -0 lines 0 comments Download
M src/layout.h View 2 chunks +20 lines, -0 lines 0 comments Download
M src/layout.cc View 1 6 chunks +410 lines, -1 line 0 comments Download
M test/SConstruct View 1 chunk +1 line, -0 lines 0 comments Download
A test/layout_common_table_test.cc View 1 chunk +732 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
bashi
Hi, I'm working on adding GPOS support. The CL could be large so at first ...
9 years, 10 months ago (2011-02-03 00:48:41 UTC) #1
Yusuke Sato
http://codereview.chromium.org/6410047/diff/1/include/ots-memory-stream.h File include/ots-memory-stream.h (right): http://codereview.chromium.org/6410047/diff/1/include/ots-memory-stream.h#newcode21 include/ots-memory-stream.h:21: virtual bool WriteRaw(const void *data, size_t length) { Please ...
9 years, 10 months ago (2011-02-04 06:12:52 UTC) #2
bashi
Hi Yusuke-san, Thank you for review. I've revised the CL. (Sorry for bothering you about ...
9 years, 10 months ago (2011-02-07 01:17:07 UTC) #3
Yusuke Sato
9 years, 10 months ago (2011-02-07 03:44:27 UTC) #4
lgtm

On 2011/02/07 01:17:07, bashik wrote:
> Hi Yusuke-san,
> 
> Thank you for review. I've revised the CL. (Sorry for bothering you about
> pointing out missing returns again..)
> 
> Thanks!
> 
> http://codereview.chromium.org/6410047/diff/1/include/ots-memory-stream.h
> File include/ots-memory-stream.h (right):
> 
>
http://codereview.chromium.org/6410047/diff/1/include/ots-memory-stream.h#new...
> include/ots-memory-stream.h:21: virtual bool WriteRaw(const void *data, size_t
> length) {
> On 2011/02/04 06:12:52, Yusuke Sato wrote:
> > Please be consistent: if you add virtual to WriteRaw, please do it for Seek
> and
> > Tell as well.
> 
> Done.
> 
> http://codereview.chromium.org/6410047/diff/1/src/gdef.cc
> File src/gdef.cc (right):
> 
> http://codereview.chromium.org/6410047/diff/1/src/gdef.cc#newcode209
> src/gdef.cc:209: const unsigned mark_sets_end = static_cast<unsigned>(4) +
> 2*mark_set_count;
> On 2011/02/04 06:12:52, Yusuke Sato wrote:
> > since file->gdef->num_mark_glyph_sets is 16bit unsigned, it might be better
to
> > check integer overflow here. If you agree, please add
> > 
> > if (mark_sets_end > std::numeric_limits<uint16_t>::max()) {
> >   return OTS_FAILURE();
> > }
> > 
> > or something similar.
> 
> Done.
> 
> http://codereview.chromium.org/6410047/diff/1/src/layout.cc
> File src/layout.cc (right):
> 
> http://codereview.chromium.org/6410047/diff/1/src/layout.cc#newcode54
> src/layout.cc:54: OTS_FAILURE();
> On 2011/02/04 06:12:52, Yusuke Sato wrote:
> > return is missing.
> 
> Done.
> 
> http://codereview.chromium.org/6410047/diff/1/src/layout.cc#newcode92
> src/layout.cc:92: OTS_FAILURE();
> On 2011/02/04 06:12:52, Yusuke Sato wrote:
> > ditto. please grep your change again.
> 
> Done.
> 
> http://codereview.chromium.org/6410047/diff/1/src/layout.cc#newcode184
> src/layout.cc:184: if (lookup_flag & kMarkAttachmentTypeMask &&
> On 2011/02/04 06:12:52, Yusuke Sato wrote:
> > I slightly prefer:
> > 
> > if ((lookup_flag & kMarkAttachmentTypeMask) &&
> > 
> > since the operator precedence of bitwise-AND is sometimes confusing (higher
> than
> > && but lower than ==, as you should know.)
> 
> Done.

Powered by Google App Engine
This is Rietveld 408576698