Developed by Visit Scand.com Scand Ltd. Contact dev team

epuBearepubear logo

Lightweight easily customizable
cross-platform EPUB SDK
for EPUB reader development

Where to apply?

What is epuBear?

EpuBear is the EPUB toolkit which facilitates the development of e-book readers. The powerful and lightweight nature of our EPUB SDK provides your apps with the basic functionality required. We prevent it from being overloaded with rare and specific features and underlined its easy-to-use nature and high customization availability.

  • Cross-platform core that is easy to modify and upgrade
  • Easy to integrate into the project
  • Not overloaded with unnecessary functionality you usually pay for
  • Fast document processing

EpuBear Demo Apps

EpuBear Demo Apps

You may download epuBear demo apps and read EPUB content on your devices. It will give you the glimpse of the general functionality and the required characteristics to meet your business needs. Feel free to use it and it will empower you with the ability to make up your mind concerning our cooperation in the development of your very own EPUB based product.

Also, upon your wish, the demo app could be used for reading E-books and other EPUB documents on your devices.

Source Code Samples

EpuBear SDK is a C++ solution and we have developed native wrappers for Java(Android), Swift(iOS) and C# (Xamarin) for our EPUB toolkit to match with any project you might have. Let's look how easily it could be integrated and applied.

The samples of the code are available here:

                        /*  Initialization  */

import com.epubear.EpubearSdk;

public class EpubearView extends View implements EpubearSdk.EventListener {

    private EpubearSdk epubear;
    private Map bitmaps;

    public EpubearView(Context context) {
        ....
        //  create instance
        epubear = new EpubearSdk(context, dataDir, userName, userKey);
        epubear.setEventListener(this);
        ....
    }

    @Override
    public void onSizeChanged(int w, int h, int oldw, int oldh) {
        ....
        //  init sdk with target width/height
        epubear.updateBitmapSize(w, h);
        ....
    }

    @Override
    public void doInitDisplay() {
        ....
        //  create bitmaps
        //  register bitmaps in sdk
        for (Map.Entry entry : bitmaps.entrySet())
            epubear.registerBitmap(entry.getKey(), bitmap.getValue());
        ....
    }
}

/*  Navigation  */

//  open epub
epubear.openFile(path);

//  go to next page
epubear.openNextPage();

//  go to previous page
epubear.openPreviousPage();

//  go to target page
epubear.openPage(n);

//  get Table of Contents
Map tocList = epubear.tableOfContents();

//  open chapter from table of contents
epubear.openChapter(caption);

//  font increase
epubear.increaseFont();

//  font increase
epubear.decreaseFont();

/*  Image Cache */
....
FragmentManager fm = getSupportFragmentManager();
if (!epubear.hasImageCache())
    epubear.useImageCache(fm, cacheSize);
....
                    
                        
// SDK initialization and book opening, if book cannot be opened returns nil
// BookViewController.swift

override func viewWillAppear(animated: Bool) {
		...
        epubearInstance = EPUBearSDK(bookPath: self.bookPath, withCachePath: self.cachePath)
        ...
        }
        
override func viewDidLayoutSubviews() {
		...
		let scale = UIScreen.mainScreen().scale;
		let scaledSize = CGSize(width: view.bounds.size.width * scale, height: view.bounds.size.height * scale);
		epubearInstance.resizeBitmapsIfNeeded(scaledSize);
		...
		}

// Bitmaps getters
epubearInstance.centerImage();
epubearInstance.leftImage();
epubearInstance.rightImage();

// Navigation through book
epubearInstance.openNextPage();
epubearInstance.openPreviousPage();
epubearInstance.openPage(page);

// Navigation through chapters
epubearInstance.openChapterAtIndex(index);

// Change font size
epubearInstance.increaseFont();
epubearInstance.decreaseFont();
                    
                 	 // BookViewController.cs

private EPUBearSDK _epubear;

public override void ViewDidLoad()
{
	base.ViewDidLoad();

	var bookPath = (Element as BookPage).BookPath;
	var cachePath = (Element as BookPage).CachePath;

	_epubear = new EPUBearSDK(bookPath, cachePath);
	_epubear.WeakDelegate = this;	// to handle callbacks
}

public override void ViewDidLayoutSubviews()
{
	...
	var viewSize = View.Bounds.Size;
	var scale = UIScreen.MainScreen.Scale;
	var scaledSize = new CGSize(viewSize.Width * scale, viewSize.Height * scale);
	_epubear.ResizeBitmapsIfNeeded(scaledSize);
	...
}

// Book Navigation
_epubear.OpenChapterAtIndex(chapterIndex);
_epubear.OpenPage(pageNumber);
_epubear.OpenPreviousPage();
_epubear.OpenNextPage();

// Change font size
_epubear.IncreaseFont();
_epubear.DecreaseFont();

// Way to access rendered pages as CGImage objects
var pages = new CGImage[3];
pages[0] = _epubear.LeftImage;
pages[1] = _epubear.CenterImage;
pages[2] = _epubear.RightImage;

// Way to check first && last pages
_epubear.CanScrollToLeft;
_epubear.CanScrollToRight;

// Way to change night\normal mode
_epubear.SetAppearanceMode(EPUBAppearanceMode);

// Framework delegate methods
IEPUBearSDKDelegate.ContentUpdated();
IEPUBearSDKDelegate.PageCountChanged(pageCount);
                    

Get epuBear SDK

Our epuBear SDK is easily integrated into your project and after the purchase it could be used right away. Also, we do hold an interest in further cooperation using epuBear SDK to build powerful EPUB readers that will serve the needs of your enterprise and bring the maximum value to your business.