ICEpdf
  1. ICEpdf
  2. PDF-1042

Customizations for Annotation UI

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 6.1.2
    • Fix Version/s: 6.1.3
    • Component/s: API, Examples
    • Labels:
      None
    • Environment:
      All

      Description

      There are a few customer requests for making customizations to which Annotations should be rendered in the Annotations Bar as well as what menu's are available on the Annotations themselves.

      Request #1: Is it possible to disable/hide one or more of the tools on the annotations bar? We would like to allow our users to access the 'Square Annotation' but not all of the other options.

      Request #2: Popup annotations show a Reply To and Set Status options on Right Click. We would like to remove these options from the menu that is displayed.

        Activity

        Hide
        Patrick Corless added a comment -

        The following properties have been added to the the Properties manager for configuration of which annotation creation tools will be enabled and made visible.

        // properties used to control visibility of annotation controls on main utility panel.
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_HIGHLIGHT = "application.toolbar.annotation.show.highlight";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_UNDERLINE = "application.toolbar.annotation.show.underline";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_STRIKE_OUT = "application.toolbar.annotation.show.strikeOut";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_LINE = "application.toolbar.annotation.show.line";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_LINK = "application.toolbar.annotation.show.link";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_ARROW = "application.toolbar.annotation.show.arrow";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_RECTANGLE = "application.toolbar.annotation.show.rectangle";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_CIRCLE = "application.toolbar.annotation.show.circle";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_INK = "application.toolbar.annotation.show.ink";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_FREE_TEXT = "application.toolbar.annotation.show.freeText";
            public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_TEXT = "application.toolbar.annotation.show.text";
            // Individual controls for the annotation toolbar button commands
            public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_SELECTION = "application.toolbar.show.annotation.selection";
            public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_HIGHLIGHT = "application.toolbar.show.annotation.highlight";
            public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_TEXT = "application.toolbar.show.annotation.text";
            // Individual control of the markup annotation context menu
            public static final String PROPERTY_SHOW_ANNOTATION_MARKUP_REPLY_TO = "application.annotation.show.markup.replyTo";
            public static final String PROPERTY_SHOW_ANNOTATION_MARKUP_SET_STATUS = "application.annotation.show.markup.setStatus";
        

        No change to the default behavour, Standard usage is a follows:

        PropertiesManager properties = new PropertiesManager(
                System.getProperties(),
                ResourceBundle.getBundle(PropertiesManager.DEFAULT_MESSAGE_BUNDLE));
        
        // setup default look of the viewer
        properties.set(PropertiesManager.PROPERTY_DEFAULT_ZOOM_LEVEL, "1.25");
        properties.setBoolean(PropertiesManager.PROPERTY_SHOW_UTILITY_ANNOTATION_HIGHLIGHT, false);
        properties.setBoolean(PropertiesManager.PROPERTY_SHOW_UTILITY_ANNOTATION_TEXT, true);
        
        SwingViewBuilder factory = new SwingViewBuilder(controller, properties);
        
        Show
        Patrick Corless added a comment - The following properties have been added to the the Properties manager for configuration of which annotation creation tools will be enabled and made visible. // properties used to control visibility of annotation controls on main utility panel. public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_HIGHLIGHT = "application.toolbar.annotation.show.highlight" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_UNDERLINE = "application.toolbar.annotation.show.underline" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_STRIKE_OUT = "application.toolbar.annotation.show.strikeOut" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_LINE = "application.toolbar.annotation.show.line" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_LINK = "application.toolbar.annotation.show.link" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_ARROW = "application.toolbar.annotation.show.arrow" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_RECTANGLE = "application.toolbar.annotation.show.rectangle" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_CIRCLE = "application.toolbar.annotation.show.circle" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_INK = "application.toolbar.annotation.show.ink" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_FREE_TEXT = "application.toolbar.annotation.show.freeText" ; public static final String PROPERTY_SHOW_UTILITY_ANNOTATION_TEXT = "application.toolbar.annotation.show.text" ; // Individual controls for the annotation toolbar button commands public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_SELECTION = "application.toolbar.show.annotation.selection" ; public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_HIGHLIGHT = "application.toolbar.show.annotation.highlight" ; public static final String PROPERTY_SHOW_TOOLBAR_ANNOTATION_TEXT = "application.toolbar.show.annotation.text" ; // Individual control of the markup annotation context menu public static final String PROPERTY_SHOW_ANNOTATION_MARKUP_REPLY_TO = "application.annotation.show.markup.replyTo" ; public static final String PROPERTY_SHOW_ANNOTATION_MARKUP_SET_STATUS = "application.annotation.show.markup.setStatus" ; No change to the default behavour, Standard usage is a follows: PropertiesManager properties = new PropertiesManager( System .getProperties(), ResourceBundle.getBundle(PropertiesManager.DEFAULT_MESSAGE_BUNDLE)); // setup default look of the viewer properties.set(PropertiesManager.PROPERTY_DEFAULT_ZOOM_LEVEL, "1.25" ); properties.setBoolean(PropertiesManager.PROPERTY_SHOW_UTILITY_ANNOTATION_HIGHLIGHT, false ); properties.setBoolean(PropertiesManager.PROPERTY_SHOW_UTILITY_ANNOTATION_TEXT, true ); SwingViewBuilder factory = new SwingViewBuilder(controller, properties);
        Hide
        Patrick Corless added a comment -

        Marking as complete.

        Show
        Patrick Corless added a comment - Marking as complete.

          People

          • Assignee:
            Patrick Corless
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: