Examples of fillGradientRectangle()


Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

              final int gradientHeight = (gradientPercents[i] * rect.height / 100) - pos;
              gc.fillGradientRectangle(0, pos, rect.width, gradientHeight, true);
              pos += gradientHeight;
            } else {
              final int gradientWidth = (gradientPercents[i] * rect.width / 100) - pos;
              gc.fillGradientRectangle(pos, 0, gradientWidth, rect.height, false);
              pos += gradientWidth;
            }
          }
          if (gradientVertical && pos < rect.height) {
            gc.setBackground(getBackground());
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

      Color oldBackground = gc.getBackground();

      /* Gradient */
      gc.setForeground(fGradientFgColor);
      gc.setBackground(fGradientBgColor);
      gc.fillGradientRectangle(0, rect.y, area.width, rect.height, true);

      /* Bottom Line */
      gc.setForeground(fGradientEndColor);
      gc.drawLine(0, rect.y + rect.height - 1, area.width, rect.y + rect.height - 1);

View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

          GC gc = e.gc;
          Rectangle clArea = descriptionContainer.getClientArea();

          gc.setForeground(fNotifierColors.getBorder());
          gc.setBackground(fNotifierColors.getGradientEnd());
          gc.fillGradientRectangle(4, 1, clArea.width, 1, false);
        }
      });

      Label descriptionText = new Label(descriptionContainer, SWT.WRAP);
      descriptionText.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

      }

      private void drawGradient(GC gc, Rectangle clArea) {
        gc.setForeground(fNotifierColors.getGradientBegin());
        gc.setBackground(fNotifierColors.getGradientEnd());
        gc.fillGradientRectangle(clArea.x, clArea.y, clArea.width, clArea.height, true);
      }

      private void fixRegion(GC gc, Rectangle clArea) {
        gc.setForeground(fNotifierColors.getBorder());
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

      }

      private void drawGradient(GC gc, Rectangle clArea) {
        gc.setBackground(fNotifierColors.getGradientBegin());
        gc.setForeground(fNotifierColors.getGradientEnd());
        gc.fillGradientRectangle(clArea.x, clArea.y, clArea.width, clArea.height, true);
      }

      private void fixRegion(GC gc, Rectangle clArea) {
        gc.setForeground(fNotifierColors.getBorder());
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

            if (lastColor == null)
              lastColor = oldBackground;
            gc.setBackground(lastColor);
            if (gradientVertical) {
              final int gradientHeight = (gradientPercents[i] * rect.height / 100) - pos;
              gc.fillGradientRectangle(0, pos, rect.width, gradientHeight, true);
              pos += gradientHeight;
            } else {
              final int gradientWidth = (gradientPercents[i] * rect.width / 100) - pos;
              gc.fillGradientRectangle(pos, 0, gradientWidth, rect.height, false);
              pos += gradientWidth;
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

              final int gradientHeight = (gradientPercents[i] * rect.height / 100) - pos;
              gc.fillGradientRectangle(0, pos, rect.width, gradientHeight, true);
              pos += gradientHeight;
            } else {
              final int gradientWidth = (gradientPercents[i] * rect.width / 100) - pos;
              gc.fillGradientRectangle(pos, 0, gradientWidth, rect.height, false);
              pos += gradientWidth;
            }
          }
          if (gradientVertical && pos < rect.height) {
            gc.setBackground(getBackground());
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

              prevEntry.getColor());

          gc.setAlpha(getAlpha(entry.getOpacity()));
          gc.setBackground(c1);
          gc.setForeground(c2);
          gc.fillGradientRectangle(1, 0, imageSize.width-2,
              imageSize.height, true);

          gc.setAlpha(150);
          gc.setForeground(display.getSystemColor(SWT.COLOR_BLACK));
          gc.drawLine(0, 0, 0, imageSize.height);
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

        Color bg = factory.getColors().getColor(IFormColors.H_GRADIENT_END);
        Color gbg = factory.getColors().getColor(IFormColors.H_GRADIENT_START);
        GC gc = e.gc;
        gc.setForeground(bg);
        gc.setBackground(gbg);
        gc.fillGradientRectangle(bounds.x, bounds.y, bounds.width, bounds.height, true);
        // background bottom separator
        gc.setForeground(factory.getColors().getColor(IFormColors.H_BOTTOM_KEYLINE1));
        gc.drawLine(bounds.x, bounds.height - 2, bounds.x + bounds.width - 1, bounds.height - 2);
        gc.setForeground(factory.getColors().getColor(IFormColors.H_BOTTOM_KEYLINE2));
        gc.drawLine(bounds.x, bounds.height - 1, bounds.x + bounds.width - 1, bounds.height - 1);
View Full Code Here

Examples of org.eclipse.swt.graphics.GC.fillGradientRectangle()

          GC gc = new GC(newImage);

          // fill background
          gc.setForeground(_bgFgGradient);
          gc.setBackground(_bgBgGradient);
          gc.fillGradientRectangle(rect.x, rect.y, rect.width, rect.height, true);

          // draw shell edge
          gc.setLineWidth(2);
          gc.setForeground(_borderColor);
          gc.drawRectangle(rect.x + 1, rect.y + 1, rect.width - 2, rect.height - 2);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.