Examples of ResizableIcon


Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

  @Before
  public void onSetUp() {
    URL resource = SplitCommandButtonTestCase.class.getClassLoader()
        .getResource("utest/common/edit-paste.svg");
    Assertions.assertThat(resource).isNotNull();
    final ResizableIcon icon = SvgBatikResizableIcon.getSvgIcon(resource,
        new Dimension(32, 32));
    Pause.pause(new Condition("Waiting to load the SVG icon") {
      @Override
      public boolean test() {
        return !((AsynchronousLoading) icon).isLoading();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

  JCommandButton button2;

  @Override
  @Before
  public void onSetUp() {
    final ResizableIcon icon1 = new edit_paste();
    final ResizableIcon icon2 = new edit_cut();

    GuiActionRunner.execute(new GuiTask() {
      @Override
      protected void executeInEDT() throws Throwable {
        buttonFrame = new JFrame();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

  JCommandButton button2;

  @Override
  @Before
  public void onSetUp() {
    final ResizableIcon icon1 = new edit_paste();
    final ResizableIcon icon2 = new edit_cut();

    GuiActionRunner.execute(new GuiTask() {
      @Override
      protected void executeInEDT() throws Throwable {
        buttonFrame = new JFrame();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

  @Before
  public void onSetUp() {
    URL resource = ActionCommandButtonTestCase.class.getClassLoader()
        .getResource("utest/common/edit-paste.svg");
    Assertions.assertThat(resource).isNotNull();
    final ResizableIcon icon = SvgBatikResizableIcon.getSvgIcon(resource,
        new Dimension(32, 32));
    Pause.pause(new Condition("Waiting to load the SVG icon") {
      @Override
      public boolean test() {
        return !((AsynchronousLoading) icon).isLoading();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

        });

    URL cutIconUrl = ActionCommandButtonTestCase.class.getClassLoader()
        .getResource("utest/common/edit-cut.svg");
    Assertions.assertThat(cutIconUrl).isNotNull();
    final ResizableIcon cutIcon = SvgBatikResizableIcon.getSvgIcon(
        cutIconUrl, new Dimension(16, 16));
    Pause.pause(new Condition("Waiting to load the SVG icon") {
      @Override
      public boolean test() {
        return !((AsynchronousLoading) cutIcon).isLoading();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

  JCommandButton button2;

  @Override
  @Before
  public void onSetUp() {
    final ResizableIcon icon1 = new edit_paste();
    final ResizableIcon icon2 = new edit_cut();

    GuiActionRunner.execute(new GuiTask() {
      @Override
      protected void executeInEDT() throws Throwable {
        buttonFrame = new JFrame();
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

        JCommandButton button = new JCommandButton(bi.getKey());
        configureBreadcrumbButton(button);
        configureMainAction(button, bi);
        final Icon icon = bi.getIcon();
        if (icon != null) {
          button.setIcon(new ResizableIcon() {
            int iw = icon.getIconWidth();
            int ih = icon.getIconHeight();

            @Override
            public void paintIcon(Component c, Graphics g, int x,
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

          JCommandMenuButton menuButton = new JCommandMenuButton(bi
              .getKey(), null);
          final Icon icon = bi.getIcon();
          if (icon != null) {
            menuButton.setIcon(new ResizableIcon() {
              int iw = icon.getIconWidth();
              int ih = icon.getIconHeight();

              @Override
              public void paintIcon(Component c, Graphics g,
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

      protected void process(List<Leaf> leaves) {
        for (final Leaf leaf : leaves) {
          final String name = leaf.getLeafName();
          InputStream stream = leaf.getLeafStream();
          Dimension dim = new Dimension(currDimension, currDimension);
          final ResizableIcon icon = getResizableIcon(leaf, stream,
              currState, dim);
          if (icon == null)
            continue;
          final JCommandButton commandButton = newButtons.get(name);
          commandButton.setIcon(icon);
View Full Code Here

Examples of org.pushingpixels.flamingo.api.common.icon.ResizableIcon

    for (int groupIndex = 0; groupIndex < 4; groupIndex++) {
      String iconGroupName = mf.format(new Object[] { groupIndex });
      this.addButtonGroup(iconGroupName, groupIndex);
      for (int i = 0; i < 15; i++) {
        final String deco = groupIndex + "/" + i;
        ResizableIcon fontIcon = new font_x_generic();
        ResizableIcon finalIcon = new DecoratedResizableIcon(fontIcon,
            new DecoratedResizableIcon.IconDecorator() {
              @Override
              public void paintIconDecoration(Component c,
                  Graphics g, int x, int y, int width,
                  int height) {
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.