From 9b65f55f536ccdac87c8cff40e14b74796da4ed1 Mon Sep 17 00:00:00 2001 From: Christophe CURIS Date: Sat, 31 May 2014 19:58:49 +0200 Subject: [PATCH] WPrefs: add warning when renderTexture encounters some unknow settings Having the warning displayed will help devs to understand what is going on and where to look at for a fix. Signed-off-by: Christophe CURIS --- WPrefs.app/Appearance.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/WPrefs.app/Appearance.c b/WPrefs.app/Appearance.c index 05354952..2d5acbe6 100644 --- a/WPrefs.app/Appearance.c +++ b/WPrefs.app/Appearance.c @@ -567,6 +567,7 @@ static Pixmap renderTexture(WMScreen * scr, WMPropList * texture, int width, int style = RHorizontalGradient; break; default: + wwarning("unknow direction in '%s', falling back to diagonal", type); case 'D': style = RDiagonalGradient; break; @@ -592,6 +593,7 @@ static Pixmap renderTexture(WMScreen * scr, WMPropList * texture, int width, int style = RHorizontalGradient; break; default: + wwarning("unknow direction in '%s', falling back to diagonal", type); case 'D': style = RDiagonalGradient; break; @@ -625,6 +627,7 @@ static Pixmap renderTexture(WMScreen * scr, WMPropList * texture, int width, int style = RHorizontalGradient; break; default: + wwarning("unknow direction in '%s', falling back to diagonal", type); case 'D': style = RDiagonalGradient; break; @@ -669,6 +672,11 @@ static Pixmap renderTexture(WMScreen * scr, WMPropList * texture, int width, int image = RScaleImage(timage, width, height); RReleaseImage(timage); break; + + default: + wwarning("type '%s' in not a supported type for a texture", type); + RReleaseImage(timage); + return None; } }