Skip to content

Commit

Permalink
StringRenderer::pen_color_: int[3]->double[3]
Browse files Browse the repository at this point in the history
  • Loading branch information
rfschtkt committed Jun 2, 2017
1 parent 42066ce commit 2981c6c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions training/stringrenderer.cpp
Expand Up @@ -101,6 +101,7 @@ StringRenderer::StringRenderer(const string& font_desc, int page_width,
page_height_(page_height),
h_margin_(50),
v_margin_(50),
pen_color_{0.0, 0.0, 0.0},
char_spacing_(0),
leading_(0),
vertical_text_(false),
Expand All @@ -120,15 +121,12 @@ StringRenderer::StringRenderer(const string& font_desc, int page_width,
start_box_(0),
page_(0),
box_padding_(0),
page_boxes_(nullptr),
total_chars_(0),
font_index_(0),
last_offset_(0) {
pen_color_[0] = 0.0;
pen_color_[1] = 0.0;
pen_color_[2] = 0.0;
set_font(font_desc);
set_resolution(kDefaultOutputResolution);
page_boxes_ = nullptr;
}

bool StringRenderer::set_font(const string& desc) {
Expand Down
2 changes: 1 addition & 1 deletion training/stringrenderer.h
Expand Up @@ -179,7 +179,7 @@ class StringRenderer {
// Page properties
int page_width_, page_height_, h_margin_, v_margin_;
// Text rendering properties
int pen_color_[3];
double pen_color_[3];
double char_spacing_;
int leading_, resolution_;
bool vertical_text_;
Expand Down

0 comments on commit 2981c6c

Please sign in to comment.