Examples of StandardPane


Examples of org.ytreza.lib.view.StandardPane

      }
    });
  }
 
  private StandardPane createMainPane() {
    return new StandardPane() {
      @Override
      protected void build() {
        setLayout(new BorderLayout());
       
        JPanel panelTwoLists = new JPanel();
       
        panelTwoLists.setLayout(new BoxLayout(panelTwoLists, BoxLayout.PAGE_AXIS));
        panelTwoLists.setComponentOrientation(ComponentOrientation.LEFT_TO_RIGHT);

        JPanel paneNoteList = createPaneNoteList();
        JPanel paneTagList = createPaneTagList();

        JSplitPane split = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
        split.setDividerLocation(150);
        split.setOneTouchExpandable(true);
       
        split.add(paneTagList);
        split.add(paneNoteList);

        panelTwoLists.add(split);
       
        add(panelTwoLists, BorderLayout.CENTER);
        add(createPaneButtons(), BorderLayout.SOUTH);
      }

      private StandardPane createPaneTagList() {
        return new StandardPane() {
          @Override
          protected void build() {
            setLayout(new BoxLayout(this, BoxLayout.PAGE_AXIS));

            paneTag = new JPanel();
            paneTag.setBackground(Color.WHITE);

            fieldListIncludedTags = new JList();
                fieldListIncludedTags.setCellRenderer(new TagListRenderer());
                fieldListIncludedTags.setLayoutOrientation(JList.VERTICAL_WRAP);
                fieldListIncludedTags.setVisibleRowCount(-1);
           
            fieldListExcludedTags = new JList();
            fieldListExcludedTags.setCellRenderer(new TagListRenderer());
            fieldListExcludedTags.setLayoutOrientation(JList.VERTICAL_WRAP);
            fieldListExcludedTags.setVisibleRowCount(-1);

            add(paneTag);
            add(fieldListIncludedTags);
            add(fieldListExcludedTags);
          }
        };
      }

      private StandardPane createPaneNoteList() {
        return new StandardPane() {
          @Override
          protected void build() {
            setLayout(new BorderLayout());
            fieldListNote = new JList() {
              @Override
              public JToolTip createToolTip() {
                    MultiLineToolTip tip = new MultiLineToolTip();
                    tip.setComponent(this);
                    return tip;
              }
            };
            fieldListNote.setCellRenderer(new NoteListRenderer());
            fieldListNote.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
           
            add(createSearchPane(), BorderLayout.NORTH);
            add(new JScrollPane(fieldListNote), BorderLayout.CENTER);
          }

          private StandardPane createSearchPane() {
            return new StandardPane() {


              @Override
              protected void build() {
                setLayout(new BorderLayout());
                fieldNoteSearch = new JTextField();
                fieldResetSearchButton = new JButton(Tr._("search.reset"));
                add(fieldNoteSearch, BorderLayout.CENTER);
                add(fieldResetSearchButton,BorderLayout.EAST);
              }
            };
          }
         
        };
      }
     
      private StandardPane createPaneButtons() {
        return new StandardPane() {
          @Override
          protected void build() {
            fieldNewButton = new JButton(Tr._("note.new"));
            add(fieldNewButton);
View Full Code Here

Examples of org.ytreza.lib.view.StandardPane

      }
    });
  }
 
  private StandardPane createMainPane() {
    return new StandardPane() {
      @Override
      protected void build() {
        setLayout(new BorderLayout());
        add(createPaneNote(), BorderLayout.CENTER);
        add(createPaneButtons(), BorderLayout.SOUTH);
      }

      private StandardPane createPaneNote() {
        return new StandardPane() {

          @Override
          protected void build() {
            setLayout(new BorderLayout());
           
            subjectField = new JTextField();
            textField = new FieldText();
            keywordsField = new JTextField();

           
            add(subjectField, BorderLayout.NORTH);
            add(new JScrollPane(textField), BorderLayout.CENTER);
            add(keywordsField, BorderLayout.SOUTH);
          }
        };
      }
     
      private StandardPane createPaneButtons() {
        return new StandardPane() {


          @Override
          protected void build() {
            fieldOkButton = new JButton(Tr._("note.ok"));
View Full Code Here

Examples of org.ytreza.lib.view.StandardPane

    setResizable(true);
    controler.start();
  }

  private StandardPane createMainPane() {
    return new StandardPane(){
      @Override
      protected void build() {
        setLayout(new BorderLayout());
        JPanel paneTree = createTreePane();
        JPanel propertyTree = createPropertyPane();

        JSplitPane split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
        split.setDividerLocation(150);
        split.setOneTouchExpandable(true);
       
        split.add(paneTree);
        split.add(propertyTree);

        add(split, BorderLayout.CENTER);
        add(createButtonPane(), BorderLayout.SOUTH);
       
      }

      private StandardPane createButtonPane() {
        return new StandardPane() {

          @Override
          protected void build() {
            buttonOk = new JButton(Tr._("property.ok"));
            buttonCancel = new JButton(Tr._("property.cancel"));
           
            add(buttonOk);
            add(buttonCancel);
          }
        };
      }

      private StandardPane createPropertyPane() {
        return new StandardPane() {
          @Override protected void build() {
            setLayout(new BoxLayout(this, BoxLayout.PAGE_AXIS));
            fieldDescription = new JLabel();
            add(fieldDescription);
           
            panelPropertyFields = createPropertyCardPane();
            add(panelPropertyFields);
           
          }

          private StandardPane createPropertyCardPane() {
            return new StandardPane() {

              @Override
              protected void build() {
                setLayout(new CardLayout());
                add(createPropertyTextPane() ,Property.class.getName());
                add(createPropertyComboPane() ,PropertyWithOptions.class.getName());
                add(createPropertyPathPane() ,PropertyWithPath.class.getName());
                add(new JPanel() ,"");
              }
             
            };
          }

          private StandardPane createPropertyPathPane() {
            return new StandardPane() {
              @Override protected void build() {
                setLayout(new BorderLayout());
                fieldPropertyPath = new JTextField();
                add(fieldPropertyPath, BorderLayout.NORTH);
              }
            };
          }

          private StandardPane createPropertyComboPane() {
            return new StandardPane() {

              @Override protected void build() {
                // TODO create combo box
                setLayout(new BorderLayout());
                fieldPropertyCombo = new JComboBox();
                add(fieldPropertyCombo, BorderLayout.NORTH);
              }
             
            };
          }

          private StandardPane createPropertyTextPane() {
            return new StandardPane() {
              @Override protected void build() {
                setLayout(new BorderLayout());
                fieldPropertyText = new JTextField();
                add(fieldPropertyText, BorderLayout.NORTH);
              }
            };
          }
        };
      }

      private StandardPane createTreePane() {
        return new StandardPane() {
          @Override protected void build() {
            setLayout(new BorderLayout());
            RootNode root = new RootNode();
            fieldTree = new JTree(root);
            add(fieldTree, BorderLayout.CENTER);
View Full Code Here

Examples of org.ytreza.lib.view.StandardPane

      }
    });
  }
 
  private StandardPane createMainPane() {
    return new StandardPane() {
      @Override
      protected void build() {
        setLayout(new BorderLayout());
       
        JPanel panelTwoLists = new JPanel();
       
        panelTwoLists.setLayout(new BoxLayout(panelTwoLists, BoxLayout.PAGE_AXIS));
        panelTwoLists.setComponentOrientation(ComponentOrientation.LEFT_TO_RIGHT);

        JPanel paneNoteList = createPaneNoteList();
        JPanel paneTagList = createPaneTagList();

        JSplitPane split = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
        split.setDividerLocation(150);
        split.setOneTouchExpandable(true);
       
        split.add(paneTagList);
        split.add(paneNoteList);

        panelTwoLists.add(split);
       
        add(panelTwoLists, BorderLayout.CENTER);
        add(createPaneButtons(), BorderLayout.SOUTH);
      }

      private StandardPane createPaneTagList() {
        return new StandardPane() {
          @Override
          protected void build() {
            setLayout(new BoxLayout(this, BoxLayout.PAGE_AXIS));

            StandardPane paneTagList = this.createPaneTagList();

            fieldListIncludedTags = new JList();
                fieldListIncludedTags.setCellRenderer(new TagListRenderer());
                fieldListIncludedTags.setLayoutOrientation(JList.VERTICAL_WRAP);
                fieldListIncludedTags.setVisibleRowCount(-1);
           
            fieldListExcludedTags = new JList();
            fieldListExcludedTags.setCellRenderer(new TagListRenderer());
            fieldListExcludedTags.setLayoutOrientation(JList.VERTICAL_WRAP);
            fieldListExcludedTags.setVisibleRowCount(-1);

            add(paneTagList);
            add(fieldListIncludedTags);
            add(fieldListExcludedTags);
          }

          private StandardPane createPaneTagList() {
            return new StandardPane() {
              @Override
              protected void build() {
                setLayout(new BorderLayout());
                paneTag = new JPanel();
                paneTag.setBackground(Color.WHITE);
                add(paneTag,BorderLayout.CENTER);
              }
            };
          }
        };
      }

      private StandardPane createPaneNoteList() {
        return new StandardPane() {
          @Override
          protected void build() {
            setLayout(new BorderLayout());
            fieldListNote = new JList() {
              @Override
              public JToolTip createToolTip() {
                    MultiLineToolTip tip = new MultiLineToolTip();
                    tip.setComponent(this);
                    return tip;
              }
            };
            fieldListNote.setCellRenderer(new NoteListRenderer());
            fieldListNote.setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
           
            add(createSearchPane(), BorderLayout.NORTH);
            add(new JScrollPane(fieldListNote), BorderLayout.CENTER);
          }

          private StandardPane createSearchPane() {
            return new StandardPane() {


              @Override
              protected void build() {
                setLayout(new BorderLayout());
                fieldNoteSearch = new JTextField();
                fieldResetSearchButton = new JButton(Tr._("search.reset"));
                add(fieldNoteSearch, BorderLayout.CENTER);
                add(fieldResetSearchButton,BorderLayout.EAST);
              }
            };
          }
         
        };
      }
     
      private StandardPane createPaneButtons() {
        return new StandardPane() {
          @Override
          protected void build() {
            fieldNewButton = new JButton(Tr._("note.new"));
            add(fieldNewButton);
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.