Skip to content

Commit

Permalink
Merge pull request #937 from fujimo-t/fix_25332
Browse files Browse the repository at this point in the history
Fix bug #25332, some sentences are not shown in help pages
  • Loading branch information
jyrkive committed Feb 28, 2017
2 parents 4e7a207 + b8456fe commit c74fcca
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/font/sdl_ttf.cpp
Expand Up @@ -303,10 +303,8 @@ static surface render_text(const std::string& text, int fontsize, const color_t&
return surface();
} else if (surfaces.size() == 1 && surfaces.front().size() == 1) {
surface surf = surfaces.front().front();
adjust_surface_alpha(surf, SDL_ALPHA_OPAQUE);
return surf;
} else {

surface res(create_compatible_surface(surfaces.front().front(),width,height));
if (res.null())
return res;
Expand All @@ -319,9 +317,8 @@ static surface render_text(const std::string& text, int fontsize, const color_t&

for(std::vector<surface>::iterator j = i->begin(),
j_end = i->end(); j != j_end; ++j) {
adjust_surface_alpha(*j, SDL_ALPHA_TRANSPARENT); // direct blit without alpha blending
SDL_Rect dstrect = sdl::create_rect(xpos, ypos, 0, 0);
sdl_blit(*j, nullptr, res, &dstrect);
blit_surface(*j, nullptr, res, &dstrect);
xpos += (*j)->w;
height = std::max<size_t>((*j)->h, height);
}
Expand Down

0 comments on commit c74fcca

Please sign in to comment.