com.ephox.editlive.ephoxaction.toolbar
Interface InlineToolbar


public interface InlineToolbar

Toolbar that renders inside the editor, attaching itself to elements. Created using ToolbarFactory.createInlineToolbar(EphoxAction,boolean).

Since:
7.5

Method Summary
 void hideToolbar()
          Hides the toolbar.
 boolean isVisible()
           
 void repositionAtCurrentPoint()
          Updates the toolbar position using the element bounds cache.
 void showToolbar()
          Shows the toolbar and calls repositionAtCurrentPoint().
 void updateBounds(Element elem)
          Updates the element bounds cache stored by the toolbar.
 

Method Detail

updateBounds

void updateBounds(Element elem)
Updates the element bounds cache stored by the toolbar.

Parameters:
elem - element the toolbar will be displayed next to

repositionAtCurrentPoint

void repositionAtCurrentPoint()
Updates the toolbar position using the element bounds cache.

Horizontally, the toolbar position is left aligned to the element bounds. If left aligning would cause the toolbar to render partially off the right side of the editor, it becomes right aligned 5px from the right side of the editor.

Vertically, the position behaviour depends on the value of the stickToTop parameter passed to ToolbarFactory.createInlineToolbar(EphoxAction,boolean):

Automatically called when a button on the toolbar is clicked.


hideToolbar

void hideToolbar()
Hides the toolbar.


showToolbar

void showToolbar()
Shows the toolbar and calls repositionAtCurrentPoint().


isVisible

boolean isVisible()
Returns:
true if the toolbar is currently visible

Copyright (c) 2005-2012 Ephox Pty Ltd. All rights reserved.