diff --git a/config/definitions b/config/definitions index cbaf62a5..92c5afa5 100644 --- a/config/definitions +++ b/config/definitions @@ -187,6 +187,10 @@ #define __MODIFIER 370 #define __FILLRULE 371 #define __TRANSPARENT 372 +#define __ROTATE 373 +#define __ROTATE_90 1 +#define __ROTATE_180 2 +#define __ROTATE_270 3 #define __KEEP_ON_TOP 453 #define __FLAGS 454 diff --git a/src/conf.h b/src/conf.h index e1d9b04c..d0e18aab 100644 --- a/src/conf.h +++ b/src/conf.h @@ -81,6 +81,7 @@ #define ICLASS_COLORMOD 370 #define ICLASS_FILLRULE 371 #define ICLASS_TRANSPARENT 372 +#define ICLASS_ROTATE 373 #define DESKTOP_DRAGDIR 400 #define DESKTOP_DRAGBAR_WIDTH 401 diff --git a/src/iclass.c b/src/iclass.c index 3b194a16..bf473abd 100644 --- a/src/iclass.c +++ b/src/iclass.c @@ -40,11 +40,12 @@ struct _imagestate { char got_colors; char unloadable; char transparent; + char pixmapfillstyle; + char bevelstyle; + char rotate; EImage *im; EImageBorder *border; - int pixmapfillstyle; EColor bg, hi, lo, hihi, lolo; - int bevelstyle; }; typedef struct { @@ -253,8 +254,11 @@ ImagestateRealize(ImageState * is) if (!is->real_file && is->im_file) is->real_file = ThemeFileFind(is->im_file); if (is->real_file) - is->im = EImageLoad(is->real_file); - + { + is->im = EImageLoad(is->real_file); + if (is->im && is->rotate) + EImageOrientate(is->im, is->rotate); + } if (!is->im) { #define S(s) ((s) ? (s) : "(null)") @@ -471,6 +475,9 @@ ImageclassConfigLoad(FILE * fs) case ICLASS_TRANSPARENT: ICToRead->transparent = strtoul(s2, NULL, 0); break; + case ICLASS_ROTATE: + ICToRead->rotate = strtoul(s2, NULL, 0); + break; case CONFIG_INHERIT: { ImageClass *ICToInherit;