Request Assist with Evince Contribution

Hello,

I’m writing to request some help with contributing to the Evince document viewer, It’s my first contribution and I find it hard to navigate through the files,

if there’s any tutorial, documentation I appreciate it if you can provide me with.

I intend to work on the feature of Highlighting text to make it easier to change colors highlights.
The code for the UI to add highlight annotations is in shell/ev-annotations-toolbar.c

Hello. Thank you for your interest in Evince.

The structure of directories is as follows:

  • shell. It has the code for the user interface. Inside, each file correspond to specific parts of the UI. For example, the code related to sidebar start with ev-sidebar, the ones to handle the document properties start with ev-properties, and so on. The application itself is ev-application.c, but as Evince can handle multiple windows, the code is separated ev-window.c.
  • libview. It is the library that provides the document view widgetry. The one to interact with the document and display it. Rendering the pages could be time consuming, therefore there is code to handle the rendering jobs, caching pages, etc. The code in shell calls libview functions to display the document.
  • libdocument. This library takes care of the operations to handle a document. If the shell wants to retrieve the document properties, then is uses the API provided here. Similarly, libview calls functions from libdocument to handle each document. A document can have pages, media to display, layers, properties, fonts, etc. The file names should be give a hint about their purpose (e.g. ev-document-annotations.c, ev-document-info.c, ev-document-find.c, and so on. libdocument provides an abstraction to handle any document supported.
  • backend. Evince supports different document types. Here is the code to handle each document type, like pdf, comics, xps. Each one implements interfaces so libdocument can handle them without knowing their internal details. In the case of pdf, it calls libpoppler, a library that can render PDF files.
  • libmisc. It is an internal library to provide widgets that cannot be self-contained in shell. For example, ev-page-action-widget.c provides a widget that is used in both previewer and shell.
  • previewer. Contains the code for print preview.
  • thumbnailer. The code of a small application that file manages can call to generate thumbnails of the documents supported by Evince.

Other directories are more standard across projects, like po (translation), help (user documentation), data (icons, dbus service description).

That said, before jumping to implement color handling for annotations, beware that in the properties dialog of each annotation you can change the color (you can explore that code). More importantly, there is already two merge requests proposing something similar: !218 and !142. Perhaps you could take a look at them, and check if that is what you would like to accomplish. If so, you can try them and provide feedback. If it were slightly similar, you can use them as base of what you would like to do.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.