Options
All
  • Public
  • Public/Protected
  • All
Menu

Colibrio Reader Framework API - Cloud license

Welcome to the Colibrio Framework API docs

This documentation has been generated from the framework source using TypeDoc.

Getting started

The two main modules in the framework are:

  • core

    This module has all types that are used throughout the framework. These types are often implementations of standards and include IEpubPublication, ILocator and IResourceProvider etc.

  • readingsystem

    This module contains all types that are more domain specific to the Colibrio Reader Framework. Here you find types such as IReaderPublication, IRenderer etc.

Combined, these modules holds all components and types needed to build a reading system.

Developer guides

In addition to this API reference you can also find getting started guides etc. at:

learn.colibrio.com

Important framework types

Here is a list of the concepts that you will come across early in your journey when creating your e-reader.

ReadingSystemEngine

ReadingSystemEngine is the entry point to the Colibrio Reading System API. It is used for loading publications, creating ReaderViews and SyncMediaPlayers.

ResourceProvider

The ResourceProvider is an abstraction hiding the details about resource retrieval from the reading system. There are several implementations of this interface. For example: OcfResourceProvider, ZipResourceProvider.

ReaderView

ReaderViews are used for displaying IReaderDocuments from an IReaderPublication. It is also used for navigating among the loaded documents, as well as synchronizing things such as annotations etc during navigation.

Renderer

A Renderer is responsible for the presentation of the ReaderPublication within a ReaderView. For example, the StackRenderer presents the publication as a series of pages stacked on top of each other like a deck of cards.

ReaderPublication

A publication that has been processed to be used by the Reading System. A ReaderPublication wraps a source publication and provides functionality for creating renderable content, full text search and more.

ReaderDocument

A ReaderDocument is a IContentDocument that has been processed by a format adapter to be used by the Reading System.

Locator

Locator instances are used for referencing specific locations (including ranges) in publications.

The Locator type is modeled after and compatible with the "External Web Resource" and "Specific Resource" types defined by the Web Annotations specification.

ContentLocation

Represents a location within a ReaderPublication and methods to extract information related to that location. A ContentLocation can be a position in the publication content, or a range across publication content.

EngineEvent

The Colibrio Reader Framework uses events to communicate changes to runtime state etc. This is the base interface for all IEngineEvents fired by the reading system. You can listen and react on events by adding a listener for the event type on a ReaderView or ReadingSystemEngine instance.

Have a look at the EngineEventTypeMap for a complete list of all EngineEvents.

ContentBlock

Colibrio represents IReaderPublication content in a TypeScript data structure called the ContentBlockTree . The ContentBlockTree contains ContentBlocks that represents a single node in an IContentDocument such as a paragraph, heading, table, list or image.

ContentPositionTimeline

Describes the contents in the ReaderView as a one-dimensional timeline of positions (character offset or page) within a publication. This is the class that you use to create a progress slider for your reader etc. You create a ContentPositionTimeline from a ReaderPublication.

ReaderViewAnnotationLayer

Annotation layers allow you to render content on top of the publication content. This can for example be used to highlight notes, search results etc. ReaderViewAnnotationLayers are also used for highlighting TTS.

SyncMediaPlayer

Used for playing synchronized media such as EPUB Media Overlays or TTS (Text-To-Speech). The SyncMediaPlayer coordinates the playback of a SyncMediaTimeline and exposes methods for controlling playback, such as play/pause/skip.

Generated using TypeDoc