mirror of https://github.com/kivy/kivy.git
Fix line_height < 1 (workaround)
This commit is contained in:
parent
8eb721a2c9
commit
457228ed81
|
@ -127,7 +127,15 @@ cdef class _SurfaceContainer:
|
|||
r.w = st.w
|
||||
r.h = st.h
|
||||
SDL_SetSurfaceAlphaMod(st, <int>(color[3] * 255))
|
||||
SDL_SetSurfaceBlendMode(st, SDL_BLENDMODE_NONE)
|
||||
if container.options['line_height'] < 1:
|
||||
"""
|
||||
We are using SDL_BLENDMODE_BLEND only when line_height < 1 as a workaround.
|
||||
Previously, We enabled SDL_BLENDMODE_BLEND also for text w/ line_height >= 1,
|
||||
but created an unexpected behavior (See PR #6507 and issue #6508).
|
||||
"""
|
||||
SDL_SetSurfaceBlendMode(st, SDL_BLENDMODE_BLEND)
|
||||
else:
|
||||
SDL_SetSurfaceBlendMode(st, SDL_BLENDMODE_NONE)
|
||||
SDL_BlitSurface(st, NULL, self.surface, &r)
|
||||
SDL_FreeSurface(st)
|
||||
|
||||
|
|
Loading…
Reference in New Issue