Search in sources :

Example 1 with AttributePanelManager

use of org.freeplane.view.swing.map.attribute.AttributePanelManager in project freeplane by freeplane.

the class ReminderHook method createTimePanel.

private void createTimePanel() {
    final TimeManagement timeManagement = new TimeManagement(this);
    final int axis = BoxLayout.Y_AXIS;
    final JTimePanel timePanel = timeManagement.createTimePanel(null, false, 1);
    modeController.getMapController().addNodeSelectionListener(new INodeSelectionListener() {

        public void onSelect(NodeModel node) {
            timePanel.update(node);
        }

        public void onDeselect(NodeModel node) {
        }
    });
    modeController.getMapController().addNodeChangeListener(new INodeChangeListener() {

        public void nodeChanged(NodeChangeEvent event) {
            final NodeModel node = event.getNode();
            if (event.getProperty().equals(getExtensionClass()) && node.equals(modeController.getMapController().getSelectedNode()))
                timePanel.update(node);
        }
    });
    timePanel.setBorder(BorderFactory.createTitledBorder(TextUtils.getText("calendar_panel")));
    final JPanel tablePanel = new AttributePanelManager(modeController).getTablePanel();
    tablePanel.setBorder(BorderFactory.createTitledBorder(TextUtils.getText("attributes_attribute")));
    final Box panel = new Box(axis);
    panel.add(timePanel);
    panel.add(tablePanel);
    final JTabbedPane tabs = (JTabbedPane) modeController.getUserInputListenerFactory().getToolBar("/format").getComponent(1);
    final JScrollPane timeScrollPane = new JScrollPane(panel, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
    UITools.setScrollbarIncrement(timeScrollPane);
    tabs.add(TextUtils.getText("calendar_attributes_panel"), timeScrollPane);
}
Also used : NodeChangeEvent(org.freeplane.features.map.NodeChangeEvent) JScrollPane(javax.swing.JScrollPane) INodeSelectionListener(org.freeplane.features.map.INodeSelectionListener) JPanel(javax.swing.JPanel) NodeModel(org.freeplane.features.map.NodeModel) INodeChangeListener(org.freeplane.features.map.INodeChangeListener) JTabbedPane(javax.swing.JTabbedPane) AttributePanelManager(org.freeplane.view.swing.map.attribute.AttributePanelManager) Box(javax.swing.Box) JTimePanel(org.freeplane.view.swing.features.time.mindmapmode.TimeManagement.JTimePanel)

Example 2 with AttributePanelManager

use of org.freeplane.view.swing.map.attribute.AttributePanelManager in project freeplane by freeplane.

the class MModeControllerFactory method createAddIns.

private void createAddIns() {
    final StyleEditorPanel panel = new StyleEditorPanel(modeController, uiFactory, true);
    final JScrollPane styleScrollPane = new JScrollPane(panel, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
    UITools.setScrollbarIncrement(styleScrollPane);
    final JComponent tabs = (JComponent) modeController.getUserInputListenerFactory().getToolBar("/format").getComponent(1);
    tabs.add(TextUtils.getText("format_panel"), styleScrollPane);
    new AttributePanelManager(modeController);
    new HierarchicalIcons();
    new AutomaticLayoutController();
    new BlinkingNodeHook();
    SummaryNode.install();
    AlwaysUnfoldedNode.install();
    FreeNode.install();
    new CreationModificationPlugin();
    modeController.addExtension(ReminderHook.class, new ReminderHook(modeController));
    new AutomaticEdgeColorHook();
    new ViewerController();
    modeController.addAction(new AddAttributeAction());
    modeController.addAction(new RemoveFirstAttributeAction());
    modeController.addAction(new RemoveLastAttributeAction());
    modeController.addAction(new RemoveAllAttributesAction());
    modeController.addAction(new AddExternalImageAction());
    modeController.addAction(new RemoveExternalImageAction());
    modeController.addAction(new ChangeExternalImageAction());
    modeController.addAction(new ShowFormatPanelAction());
    modeController.addAction(new FitToPage());
    MEncryptionController.install(new MEncryptionController(modeController));
    modeController.addAction(new IconSelectionPlugin());
    modeController.addAction(new NewParentNode());
    modeController.addAction(new SaveAll());
    modeController.addAction(new SortNodes());
    modeController.addAction(new SplitNode());
    new ChangeNodeLevelController(modeController);
    NodeHistory.install(modeController);
    modeController.addAction(new ImportMindmanagerFiles());
}
Also used : StyleEditorPanel(org.freeplane.features.styles.mindmapmode.StyleEditorPanel) CreationModificationPlugin(org.freeplane.features.time.CreationModificationPlugin) RemoveFirstAttributeAction(org.freeplane.features.attribute.mindmapmode.RemoveFirstAttributeAction) AutomaticLayoutController(org.freeplane.features.styles.AutomaticLayoutController) AddAttributeAction(org.freeplane.features.attribute.mindmapmode.AddAttributeAction) MEncryptionController(org.freeplane.features.encrypt.mindmapmode.MEncryptionController) AutomaticEdgeColorHook(org.freeplane.features.edge.mindmapmode.AutomaticEdgeColorHook) ImportMindmanagerFiles(org.freeplane.features.export.mindmapmode.ImportMindmanagerFiles) RemoveExternalImageAction(org.freeplane.view.swing.features.filepreview.RemoveExternalImageAction) FitToPage(org.freeplane.view.swing.features.FitToPage) ChangeNodeLevelController(org.freeplane.features.map.mindmapmode.ChangeNodeLevelController) ShowFormatPanelAction(org.freeplane.features.styles.mindmapmode.ShowFormatPanelAction) ViewerController(org.freeplane.view.swing.features.filepreview.ViewerController) RemoveAllAttributesAction(org.freeplane.features.attribute.mindmapmode.RemoveAllAttributesAction) BlinkingNodeHook(org.freeplane.view.swing.features.BlinkingNodeHook) SplitNode(org.freeplane.features.text.mindmapmode.SplitNode) RemoveLastAttributeAction(org.freeplane.features.attribute.mindmapmode.RemoveLastAttributeAction) SortNodes(org.freeplane.features.text.mindmapmode.SortNodes) IconSelectionPlugin(org.freeplane.features.icon.mindmapmode.IconSelectionPlugin) SaveAll(org.freeplane.features.url.mindmapmode.SaveAll) JScrollPane(javax.swing.JScrollPane) AddExternalImageAction(org.freeplane.view.swing.features.filepreview.AddExternalImageAction) NewParentNode(org.freeplane.features.map.mindmapmode.NewParentNode) JComponent(javax.swing.JComponent) AttributePanelManager(org.freeplane.view.swing.map.attribute.AttributePanelManager) HierarchicalIcons(org.freeplane.features.icon.HierarchicalIcons) ChangeExternalImageAction(org.freeplane.view.swing.features.filepreview.ChangeExternalImageAction) ReminderHook(org.freeplane.view.swing.features.time.mindmapmode.ReminderHook)

Aggregations

JScrollPane (javax.swing.JScrollPane)2 AttributePanelManager (org.freeplane.view.swing.map.attribute.AttributePanelManager)2 Box (javax.swing.Box)1 JComponent (javax.swing.JComponent)1 JPanel (javax.swing.JPanel)1 JTabbedPane (javax.swing.JTabbedPane)1 AddAttributeAction (org.freeplane.features.attribute.mindmapmode.AddAttributeAction)1 RemoveAllAttributesAction (org.freeplane.features.attribute.mindmapmode.RemoveAllAttributesAction)1 RemoveFirstAttributeAction (org.freeplane.features.attribute.mindmapmode.RemoveFirstAttributeAction)1 RemoveLastAttributeAction (org.freeplane.features.attribute.mindmapmode.RemoveLastAttributeAction)1 AutomaticEdgeColorHook (org.freeplane.features.edge.mindmapmode.AutomaticEdgeColorHook)1 MEncryptionController (org.freeplane.features.encrypt.mindmapmode.MEncryptionController)1 ImportMindmanagerFiles (org.freeplane.features.export.mindmapmode.ImportMindmanagerFiles)1 HierarchicalIcons (org.freeplane.features.icon.HierarchicalIcons)1 IconSelectionPlugin (org.freeplane.features.icon.mindmapmode.IconSelectionPlugin)1 INodeChangeListener (org.freeplane.features.map.INodeChangeListener)1 INodeSelectionListener (org.freeplane.features.map.INodeSelectionListener)1 NodeChangeEvent (org.freeplane.features.map.NodeChangeEvent)1 NodeModel (org.freeplane.features.map.NodeModel)1 ChangeNodeLevelController (org.freeplane.features.map.mindmapmode.ChangeNodeLevelController)1