aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--generic/tkZinc.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/generic/tkZinc.c b/generic/tkZinc.c
index 433535c..1a8a3f0 100644
--- a/generic/tkZinc.c
+++ b/generic/tkZinc.c
@@ -5082,8 +5082,10 @@ Configure(Tcl_Interp *interp,/* Used for error reporting. */
if (wi->relief_grad) {
ZnFreeGradient(wi->relief_grad);
}
- wi->relief_grad = ZnGetReliefGradient(interp, wi->win,
- ZnNameOfColor(color), alpha);
+ if (wi->relief != RELIEF_FLAT) {
+ wi->relief_grad = ZnGetReliefGradient(interp, wi->win,
+ ZnNameOfColor(color), alpha);
+ }
}
if (CONFIG_PROBE(BACK_COLOR_SPEC) || CONFIG_PROBE(LIGHT_ANGLE_SPEC)) {
bbox.orig.x = bbox.orig.y = 0;
@@ -6522,7 +6524,7 @@ Repair(WidgetInfo *wi)
glVertex2f(wi->highlight_width, wi->highlight_width);
glEnd();
}
- if (wi->border_width > 0) {
+ if ((wi->border_width > 0) && (wi->relief != RELIEF_FLAT)) {
ZnPoint p[5];
p[4].x = p[4].y = p[3].y = p[1].x = wi->highlight_width;
@@ -6613,7 +6615,7 @@ Repair(WidgetInfo *wi)
/*
* Redraw the borders.
*/
- if (wi->border_width > 0) {
+ if ((wi->border_width > 0) && (wi->relief != RELIEF_FLAT)) {
Pixmap save;
XRectangle r;