[Okular-devel] Better separation of okular core library from the frontend

Albert Astals Cid aacid at kde.org
Sun Apr 29 13:19:24 UTC 2012


El Dissabte, 28 d'abril de 2012, a les 22:19:06, Bogdan Cristea va escriure:
> Hi

Hi
 
> The latest sources for okular contain a call to Settings::instance() method
> in Part constructor which seems to be mandatory even when using only okular
> core library. Please ensure a better separation of okular core library from
> the frontend.
> 
> Below is the code snipped I use:
> 
> Settings::instance("");
> Document doc(NULL);
> 
> With previous versions of okular the first line is not needed (the instance
> method does not even exist). Latest version use this call and the Document
> constructor needs an instance of the Settings class in order to continue.
> 
> Same problem for the observers: I need to add a custom observer in order to
> check if the page has a pixmap
> 
> if(false == page->hasPixmap(MY_OBSERVER_ID, -1, -1))
> 
> and to make pixmap requests
> 
> PixmapRequest *pr = new PixmapRequest(MY_OBSERVER_ID, page->number(), page-
> 
> >width(), page->height(), 0, false);
> 
> Again, when using only the okular core library this seems pointless.

Yes, as i said the okularcore library is not designed for use in other 
frontends, and yes, this are shortcomings i already knew of. Do you plan 
working on fixing them?

Cheers,
  Albert

> 
> regards


More information about the Okular-devel mailing list