|
|
|
@ -340,7 +340,7 @@ |
|
|
|
|
decoder->zone = decoder->zones; |
|
|
|
|
zone = decoder->zones; |
|
|
|
|
|
|
|
|
|
builder->path_begun = 0; |
|
|
|
|
builder->parse_state = T1_Parse_Start; |
|
|
|
|
|
|
|
|
|
hinter = (T1_Hints_Funcs)builder->hints_funcs; |
|
|
|
|
|
|
|
|
@ -556,7 +556,7 @@ |
|
|
|
|
decoder->num_flex_vectors = 0; |
|
|
|
|
if ( start_point( builder, x, y ) || |
|
|
|
|
check_points( builder, 6 ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case 2: /* add flex vectors */ |
|
|
|
@ -747,6 +747,8 @@ |
|
|
|
|
case op_hsbw: |
|
|
|
|
FT_TRACE4(( " hsbw" )); |
|
|
|
|
|
|
|
|
|
builder->parse_state = T1_Parse_Have_Width; |
|
|
|
|
|
|
|
|
|
builder->left_bearing.x += top[0]; |
|
|
|
|
builder->advance.x = top[1]; |
|
|
|
|
builder->advance.y = 0; |
|
|
|
@ -772,6 +774,8 @@ |
|
|
|
|
case op_sbw: |
|
|
|
|
FT_TRACE4(( " sbw" )); |
|
|
|
|
|
|
|
|
|
builder->parse_state = T1_Parse_Have_Width; |
|
|
|
|
|
|
|
|
|
builder->left_bearing.x += top[0]; |
|
|
|
|
builder->left_bearing.y += top[1]; |
|
|
|
|
builder->advance.x = top[2]; |
|
|
|
@ -792,14 +796,16 @@ |
|
|
|
|
FT_TRACE4(( " closepath" )); |
|
|
|
|
|
|
|
|
|
close_contour( builder ); |
|
|
|
|
builder->path_begun = 0; |
|
|
|
|
if ( builder->parse_state != T1_Parse_Have_Path ) |
|
|
|
|
goto Syntax_Error; |
|
|
|
|
builder->parse_state = T1_Parse_Have_Width; |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case op_hlineto: |
|
|
|
|
FT_TRACE4(( " hlineto" )); |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
x += top[0]; |
|
|
|
|
goto Add_Line; |
|
|
|
@ -809,7 +815,11 @@ |
|
|
|
|
|
|
|
|
|
x += top[0]; |
|
|
|
|
if ( !decoder->flex_state ) |
|
|
|
|
builder->path_begun = 0; |
|
|
|
|
{ |
|
|
|
|
if ( builder->parse_state == T1_Parse_Start ) |
|
|
|
|
goto Syntax_Error; |
|
|
|
|
builder->parse_state = T1_Parse_Have_Moveto; |
|
|
|
|
} |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case op_hvcurveto: |
|
|
|
@ -817,7 +827,7 @@ |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) || |
|
|
|
|
check_points( builder, 3 ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
x += top[0]; |
|
|
|
|
add_point( builder, x, y, 0 ); |
|
|
|
@ -832,14 +842,14 @@ |
|
|
|
|
FT_TRACE4(( " rlineto" )); |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
x += top[0]; |
|
|
|
|
y += top[1]; |
|
|
|
|
|
|
|
|
|
Add_Line: |
|
|
|
|
if ( add_point1( builder, x, y ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case op_rmoveto: |
|
|
|
@ -848,7 +858,11 @@ |
|
|
|
|
x += top[0]; |
|
|
|
|
y += top[1]; |
|
|
|
|
if ( !decoder->flex_state ) |
|
|
|
|
builder->path_begun = 0; |
|
|
|
|
{ |
|
|
|
|
if ( builder->parse_state == T1_Parse_Start ) |
|
|
|
|
goto Syntax_Error; |
|
|
|
|
builder->parse_state = T1_Parse_Have_Moveto; |
|
|
|
|
} |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case op_rrcurveto: |
|
|
|
@ -856,7 +870,7 @@ |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) || |
|
|
|
|
check_points( builder, 3 ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
x += top[0]; |
|
|
|
|
y += top[1]; |
|
|
|
@ -876,7 +890,7 @@ |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) || |
|
|
|
|
check_points( builder, 3 ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
y += top[0]; |
|
|
|
|
add_point( builder, x, y, 0 ); |
|
|
|
@ -891,7 +905,7 @@ |
|
|
|
|
FT_TRACE4(( " vlineto" )); |
|
|
|
|
|
|
|
|
|
if ( start_point( builder, x, y ) ) |
|
|
|
|
goto Memory_Error; |
|
|
|
|
goto Fail; |
|
|
|
|
|
|
|
|
|
y += top[0]; |
|
|
|
|
goto Add_Line; |
|
|
|
@ -901,7 +915,11 @@ |
|
|
|
|
|
|
|
|
|
y += top[0]; |
|
|
|
|
if ( !decoder->flex_state ) |
|
|
|
|
builder->path_begun = 0; |
|
|
|
|
{ |
|
|
|
|
if ( builder->parse_state == T1_Parse_Start ) |
|
|
|
|
goto Syntax_Error; |
|
|
|
|
builder->parse_state = T1_Parse_Have_Moveto; |
|
|
|
|
} |
|
|
|
|
break; |
|
|
|
|
|
|
|
|
|
case op_div: |
|
|
|
@ -1072,6 +1090,7 @@ |
|
|
|
|
|
|
|
|
|
FT_TRACE4(( "..end..\n\n" )); |
|
|
|
|
|
|
|
|
|
Fail: |
|
|
|
|
return error; |
|
|
|
|
|
|
|
|
|
Syntax_Error: |
|
|
|
@ -1079,9 +1098,6 @@ |
|
|
|
|
|
|
|
|
|
Stack_Underflow: |
|
|
|
|
return PSaux_Err_Stack_Underflow; |
|
|
|
|
|
|
|
|
|
Memory_Error: |
|
|
|
|
return builder->error; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|