GlyphIcon

A GlyphIcon writes a <span> element with the chosen glyphIcon as class to the output. It’s possible to compose your own glyphIcon strings but the GlyphIcon viewElement has a whole set of GlyphIcons predefined.

Element and builder

The GlyphIcon extends the IconViewElement which holds the information needed the render the BootstrapUiElements.ICON. A builder can be created using BootstrapUiBuilders.glyphIcon factory methods.

The IconViewElement also has a Favicon implementation.

GlyphIcon attributes

Attribute Description Default

glyphIcon

A string that defines the glyphIcon to render. For example "glyphicon-console".

Not set by default

Examples

Creating a basic GlyphIcon

Given the following builder configuration

BootstrapUiBuilders.glyphIcon( GlyphIcon.ZOOM_IN );

The following markup would be rendered:

<span aria-hidden="true" class="glyphicon glyphicon-zoom-in"></span>