-*- org -*-
* Version 1.3.0 (Under Development)

* Version 1.2.1
** Functionality fixes
- Fix: Replace obsolete ~registerv-make~ with ~cl-defstruct~ #333
  + The ~registerv-make~ function was removed in Emacs 30. This change updates pdf-tools to use the modern ~cl-defstruct~ approach for register support, ensuring compatibility with Emacs 30+.
- Fix: Use correct key function for filtering page links in pdf-virtual #327
  + Fixes an issue where virtual PDF page links were not filtered correctly.

** Native compilation fixes
- Fix: Resolve all native-comp warnings across multiple files #333
  + Added ~declare-function~ declarations to pdf-cache, pdf-info, pdf-util, and pdf-view to eliminate byte-compilation and native-comp warnings.
  + Fixed docstring formatting issues that caused native-comp warnings.

** Installation and platform compatibility improvements
- Add ~doas~ as privilege escalation fallback in autobuild #323
  + The autobuild script now supports ~doas~ (used on Alpine Linux and OpenBSD) as an alternative to ~sudo~ for installing dependencies.

** Infrastructure
- Move CI from CircleCI/AppVeyor to GitHub Actions
  + All testing now runs on GitHub Actions with a unified workflow for Ubuntu, macOS, and Windows.
  + Pre-built Windows binaries are now available as artifacts from CI runs.

* Version 1.2.0
** New functionality to improve overall user experience
- Allow creation of markup annotations without a text selection @astoff #191
  + This means that you can now highlight an exact region, for example on OCR PDFs! Just select the region by holding down the Meta key and dragging the mouse. Then invoke ~pdf-annot-add-highlight-markup-annotation~ (with ~C-c C-a h~) and voila!
  + Please note that *only the highlight markup annotation* is supported on rectangular regions.
- Add option to display page labels in mode line @rafaelbeirigo #331
  + PDFs with custom page labels (Roman numerals, section numbering) can now show these labels in the mode-line. Enable with ~pdf-view-mode-line-position-use-labels~.
- Add ~pdf-metadata-buffer-mode~ for the metadata buffer @aidan-hall #305
  + The metadata buffer now has its own major mode derived from ~special-mode~, allowing you to press ~q~ to close it.
- Add horizontal scrolling support via mouse wheel @aikrahguzar #234
  + ~mwheel-scroll-left-function~ and ~mwheel-scroll-right-function~ are now properly set in ~pdf-view-mode~.
- Allow ~scroll-other-window~ to work in pdf-view buffers @whatacold #280
  + You can now scroll a PDF buffer from another window using ~C-M-v~ and ~C-M-S-v~.
- Add gamma correction option to midnight mode @vizziv #329
  + New customization options for gamma correction to improve contrast of colorful text in midnight mode. Also fixes a color conversion bug (dividing by 256 instead of 255).

** Functionality improvements and fixes
- Allow setting ~selection-style~ via the Easy Menu @astoff #190
- Improve the experience of editing Annotations @astoff #192
- Enable ~pdf-view-dark-minor-mode~ automatically if the current Emacs theme is dark #166
- Fix: Use ~kill-current-buffer~ instead of deprecated ~kill-this-buffer~ @michaelmhoffman #330
  + Fixes keybinding issue in Emacs 30. Closes #287.
- Fix: Use absolute line number in ~pdf-sync-forward-correlate~ @haselwarter #222
  + Forward sync now works correctly in narrowed buffers.
- Fix: Support pdf-buffer bookmarks in workspace managers @aikrahguzar #188
  + Bookmark restoration no longer assumes the buffer is displayed, fixing errors with workspace managers like ~activities.el~, ~burly.el~, and ~tabspaces.el~.
- Fix: Suppress errors when scrolling past document boundaries with ~C-n~ / ~C-p~ @benthamite #303
  + ~pdf-view-next-line-or-next-page~ and ~pdf-view-previous-line-or-previous-page~ no longer throw errors at document boundaries when ~debug-on-error~ is enabled.
- Fix: Set slice to common bounding box across all pages @tpapp #326
  + ~pdf-view-set-slice-from-bounding-box~ now computes the bounding box from all pages, not just the current page. Closes #325.
- Fix: Annotation sync error "No such annotation" @bramadams #260
  + Refreshes annotations on the current page to keep buffer and file in sync. Closes #246.

** Installation and platform compatibility improvements
- Add support for MSYS2 UCRT64 environment on Windows @legends2k #308
  + UCRT64 is the recommended default MSYS2 environment. This change adds proper detection and fixes build issues with GCC 14+. Closes #282, #286.
- Fix: Replace deprecated ~tempnam~ with ~mkstemp~ / ~_tempnam~ @wyuenho #309
  + Uses platform-appropriate secure temp file creation. Closes #110.
- Add support for Android Emacs using Termux @johanwiden #230
  + ~pdf-tools-install~ now works on Android Emacs via Termux. Note: This is not an officially supported platform, and touchscreen gestures have limitations.
- Add support for Nobara Linux (Fedora derivative) @gs-101 #301
- Add GNU Guix installation instructions to README @bird-dancer #315
- Update README with clearer installation prerequisites @CalumFreeman #289
- Add Makefile target to generate autoloads @Thaodan #238

* Version 1.1.0
** New functionality to improve overall user experience
- Make ~selection-style~ configurable when selecting text, via ~pdf-view-selection-style~ @hrdl-github #73
  + This feature enabled us to change the default ~selection-style~ used in ~pdf-tools~ from =GLYPH= to =WORD=.
  + The change makes highlighting / selecting text *much* snappier. If you want to go back to the old behaviour of selecting by glyph instead of word, or if you want to select a whole line instead, customize ~pdf-view-selection-style~

- Track rotation of pages and add a command to make rotation of pages easy @vizs #165
  + The new command is bound to =R= in ~pdf-view-mode-map~.

- Add support for maintaining hue in ~pdf-view-midnight-minor-mode~ using the OKLab color space @smithzvk #69 #197
  + This inversion method is now enabled by default and can be controlled by the ~pdf-view-midnight-invert~ variable. Check out the images in the PR for how beautiful the colors look in midnight mode now.
  + Also thanks to @Atreyagaurav for pushing fixes which improved this feature.

** Functionality improvements and fixes
- Fix: Saving a PDF when ~buffer-file-name~ is missing will now prompt for a filename (eg: in EWW) @akater #178
- Fix: Ensure ~pixel-scroll-precision-mode~ is deactivated correctly @mssdvd #206

** Installation and platform compatibility improvements
Please note: as of this release, users are not expected to manually set anything on their machines during installation. (for example: ~$PKG_CONFIG_PATH~). The installation should *just work*. If it does not, please open a ticket so that we can track it.

- Add ~cairo-devel~ to Void Linux package list @crzjp #203

* Version 1.0.0
From this version onward, we will follow Semantic Versioning for new ~pdf-tools~ releases.

** Breaking changes:
*** Raise the minimum supported version of Emacs to 26.3 #26
Drop support for Emacs 24 and 25. This allows for some code cleanup. *This is a major breaking change*.
*** Change the default value of pdf-view-use-scaling #133
~pdf-view-use-scaling~ is now true by default, leading to rendering of crisp images on high-resolution screens. This should not cause problems on low-resolution screen (other than taking up more cache space / increasing rendering time), but if it does, please ~(setq pdf-view-use-scaling nil)~ in your configuration.

** Improve overall user experience
- Set ~pdf-annot-list-highlight-type~ to true by default.
  + Show annotation color when listing them by default, allow the user to turn them off if need be.

** Make changes required by newer versions of Emacs
- Emacs 29 introduces ~pixel-scroll-precision-mode~, which interferes with ~pdf-view~ scrolling. This is fixed in #124

** Functionality fixes and improvements
- Fix ~revert-buffer~ to correctly work over Tramp #128
- Fix sorting by date in ~pdf-annot-list-mode~ #75

* Version 0.91
** Change the keybindings for traversing history
This is a minor but *breaking change*. ~l~ (backward) and ~r~ (forward) are the conventional bindings for history navigation in Emacs, but ~pdf-tools~ uses ~B~ and ~N~. The previous keybindings are kept as-is for people who were used to it, while introducing ~l~ and ~r~ keybindings as well.

This is a breaking change because ~r~ was previously bound to ~revert-buffer~. However, ~g~ is also bound to ~revert-buffer~ and is the conventional binding for ~revert~ so this should be okay.

** Make changes required by newer versions of Emacs
A number of changes are made to support new elisp / package changes. There is no impact of this on existing users.
- Emacs 27, Emacs 28 and Emacs 29 are supported now.
- Synctex 1.21 is supported now.
** Improve overall install experience
Running ~M-x pdf-tools-install~ should _just work_ now.
** Add support for high-resolution displays (Retina display on Mac)
Setting ~pdf-view-use-scaling~ to a non-nil value now renders crisp images on high-resolution displays.
* Version 0.90
** The displayed columns when listing annotations is now customizable
See variable ~pdf-annot-list-format~ and ~pdf-annot-list-highlight-type~.
** Improved handling of default annotation properties
A new variable ~pdf-annot-default-annotation-properties~ was introduced, subsuming and obsoleting ~pdf-annot-default-text-annotation-properties~ and ~pdf-annot-default-markup-annotation-properties~. The new variable lets the user choose default properties, e.g. a color, for all supported annotations separately.
** Provide a faster "boot-loader"
The autoloaded function ~pdf-loader-install~ acts as a replacement for ~pdf-tools-install~ and makes Emacs load and use PDF Tools as soon as a PDF file is opened, but not sooner.
** Improved the process of (re)compiling the server
This obsoletes the variable ~pdf-tools-handle-upgrades~, which does nothing anymore.
* Version 0.80
** Tablist package
The files ~tablist.el~ and ~tablist-filter.el~ are no longer part of ~pdf-tools~, but continue to live on in the ~tablist~ package, on which ~pdf-tools~ now depends on.
** View
*** Encrypted files
When encountering an encrypted file, query for a password and attempt to decrypt it.
*** Backward sync from isearch
In ~isearch~, press ~M-s s~ to visit the source of the current match.
*** Disable unicode in mode-line
New variable ~pdf-view-use-unicode-lighter~ which allows for disabling the use of unicode in the mode-line.
* Version 0.70
** View
*** Register integration
The keys ~m~ and ~'~ now set respectively to jump to a register corresponding to a position in the PDF. Also ~''~ is handled special: It jumps to the position before the last register-jump.
*** Export parts of a page as an image
See ~pdf-view-extract-region-image~.
** Info
*** Interface changes
The return value of many pdf-info-* functions was changed in order to prefer alists over other data-structures (indexed lists, trees).
** Virtual PDF
A virtual PDF is a collection of pages (or parts thereof) of arbitrary documents, which appear to the rest of ~pdf-tools~ as one big PDF, though they are always read-only.

* Version 0.60
** Regexp support
You may now search for perl-compatible regular expressions (PCRE) in PDF documents, both via Isearch and Occur. If that scares you, customize the variable ~pdf-occur-prefer-string-search~.
** Occur
*** Asynchronous search
Searching is performed asynchronously in a private server instance, i.e. it doesn't block neither ordinary editing nor ~pdf-view-mode~.
*** Moccur
Added the ability to search multiple documents in one occur buffer.
** Isearch
*** Occur Integration
~M-s o~ now starts occur, while keeping the isearch session, like it is in text-buffers.
*** Word search
~M-s w~ now does a word search, which will also find hyphenated words (as determined by ~pdf-isearch-hyphenation-character~), though not at page boundaries.
** View
*** Navigate by pagelabels
~M-g l~ may be used to jump to a page by label, i.e. its displayed number.
*** Rendering
Added the ability to display the page as it would be printed (e.g. w/o annotations) via ~pdf-view-printer-minor-mode~ and to apply a color filter via ~pdf-view-midnight-minor-mode~.
** Outline
New option ~pdf-outline-display-labels~, determining whether to display labels instead of plain page-numbers.
* Version 0.50
** PDF Tools is now available on MELPA.
** SyncTeX
*** File name handling
SyncTeX is pretty picky about source filenames. So instead of trying various filenames and hoping for best, we find it by directly inspecting the database.
*** Heuristic backward search
Backward searching now tries to find the exact position in the LaTeX buffer. This may be disabled by setting ~pdf-sync-backward-use-heuristic~ to ~nil~.
*** Renamed most variables/functions/commands.
The old ones are still there but declared obsolete.
** Compatible with Emacs 24.3
** Integrate with bookmark.el
** Compiling on OSX
PDF Tools should now compile on OSX, though it is unsupported.
** MELPA
Try to handle an update via MELPA by ~package.el~ by shutting down the server, recompiling and restarting it. This may be deactivated by setting ~pdf-tools-handle-upgrades~ to nil.
** Auto slicing
A new minor mode which will automatically slice the page according to its bounding box.
* Version 0.40
I basically reimplemented the whole thing. (Not really, but a lot has changed.)
** Displaying PDF Files.
Rendering is now done almost completely in ~libpoppler~ (no convert anymore), while PNG images are kept in memory and files are solely used as a means of exchange between Emacs and ~epdfinfo~. In essence, display should be much faster.
*** New Major Mode pdf-view
Hacking up ~doc-view.el~ to support a server-based *rendering engine* would have been to awkward. So a new major-mode was needed : ~pdf-view-mode~. Both are very similar regarding user-interface. Some differences are:
+ Setting the width to ~fit-width~, ~fit-height~ or ~fit-page~ keeps up with window-size changes.
+ The values of the slice are relative, i.e. independent of the ~image-size~.
*** PNG Image Cache
Image data is cached, in order to keep the time it needs to display a page low. Some pages are pre-loaded for the same reason, while idling. The number of cached images per buffer may be customized using ~pdf-cache-image-limit~.
** Annotations
*** New supported types
Provided ~epdfinfo~ was build with a recent version of ~libpoppler~, you may now create and modify the following markup annotation types: highlight, squiggly, underline and strike-out.
** Various
*** You may now select extended regions with C-mouse-1.
*** Numerous other changes
