diff --git a/animation_workbench/metadata.txt b/animation_workbench/metadata.txt index 805ccb2..b814889 100644 --- a/animation_workbench/metadata.txt +++ b/animation_workbench/metadata.txt @@ -4,7 +4,7 @@ description=A plugin to let you build animations in QGIS about=QGIS Animation Bench exists because we wanted to use all the awesome cartography features in QGIS and make cool, animated maps! QGIS already includes the Temporal Manager which allows you to produce animations for time-based data. But what if you want to make animations where you travel around the map, zooming in and out, and perhaps making features on the map wiggle and jiggle as the animation progresses? That is what the animation workbench tries to solve... version=1.2 qgisMinimumVersion=3.0 -author=Tim Sutton, Nyall Dawson, +author=Tim Sutton, Nyall Dawson, Jeremy Prior email=tim@kartoza.com repository=https://github.com/timlinux/QGISAnimationPlugin license=GPLv2 diff --git a/docs/.gitignore b/docs/.gitignore index 1320f90..26275ba 100644 --- a/docs/.gitignore +++ b/docs/.gitignore @@ -1 +1,2 @@ site +templates/styles.scss diff --git a/docs/default.nix b/docs/default.nix index 8283035..bece487 100644 --- a/docs/default.nix +++ b/docs/default.nix @@ -27,6 +27,8 @@ in pkgs.mkShell rec { pythonPackages.numpy pythonPackages.requests pythonPackages.pygobject3 + # Doesnt work properly + #python311Packages.cffi # In this particular example, in order to compile any binary extensions they may # require, the Python modules listed in the hypothetical requirements.txt need @@ -41,15 +43,21 @@ in pkgs.mkShell rec { libzip zlib gnused - httplz # for serving up the static site while testing + rpl ]; # Run this command, only after creating the virtual environment postVenvCreation = '' unset SOURCE_DATE_EPOCH - pip install -r requirements.txt + pip install -r requirements.txt + # Need to manually install this because of https://github.com/comwes/mkpdfs-mkdocs-plugin/pull/15 + pip install -e git+https://github.com/jwaschkau/mkpdfs-mkdocs-plugin.git#egg=mkpdfs-mkdocs + rpl -R "from weasyprint.fonts import FontConfiguration" "from weasyprint.text.fonts import FontConfiguration" .venv/src/mkpdfs-mkdocs/mkpdfs_mkdocs/mkpdfs.py + rpl -R "from weasyprint.fonts import FontConfiguration" "from weasyprint.text.fonts import FontConfiguration" .venv/lib/python3.11/site-packages/mkpdfs_mkdocs/generator.py ''; + shellHook = '' + ''; # Now we can execute any commands within the virtual environment. # This is optional and can be left out to run pip manually. postShellHook = '' diff --git a/docs/mkdocs-pdf.yml b/docs/mkdocs-pdf.yml index a72cb2d..2e834fd 100644 --- a/docs/mkdocs-pdf.yml +++ b/docs/mkdocs-pdf.yml @@ -2,60 +2,62 @@ # scripts for how this is used plugins: - - mkpdfs: - company: Kartoza - author: Tim Sutton and Nyall Dawson + #- mkpdfs: + # company: Kartoza + # author: Tim Sutton, Nyall Dawson and Jeremy Prior + # output_path: ../pdfs/QGISAnimationWorkbench.pdf + # design: templates/styles.scss # Alternative PDF creation system but no longer works # - #- with-pdf: - # # Generate the whole site as a single PDF - # # Full details on this plugin here: - # # https://github.com/orzih/mkdocs-with-pdf - # # And don't get it confused with https://github.com/zhaoterryy/mkdocs-pdf-export-plugin - # # which is intended to export a single page at a time - # output_path: ../pdfs/QGISAnimationWorkbench.pdf - # author: Tim Sutton, Nyall Dawson - # # copyright will draw in page.bottom-right - # # do it manually in templates/styles.scss - # # for more control - # # if you comment out here or use an empty string, - # # the copyright text from mkdocs-base.yml will be - # # used instead - # copyright: ' ' - # cover: true # see templates/cover.html - # back_cover: true - # cover_title: The QGIS Animation Workbench - # cover_subtitle: Bring your QGIS maps to life! - # cover_logo: ../resources/img/logo/animation-workbench-logo.svg - # # Print css is defined in templates/styles.scss - # #custom_template_path: TEMPLATES PATH - # # - # toc_title: Contents - # #heading_shift: false - # # Set to 0 so that it does not generate chapter numbering - # # we do the numbering in styles.css rather - # toc_level: 0 - # ordered_chapter_level: 0 - # #excludes_children: - # # - 'release-notes/:upgrading' - # # - 'release-notes/:changelog' - # # - # #exclude_pages: - # # - 'bugs/' - # # - 'appendix/contribute/' - # #convert_iframe: - # # - src: IFRAME SRC - # # img: POSTER IMAGE URL - # # text: ALTERNATE TEXT - # # - src: ... - # #two_columns_level: 3 - # # - # #render_js: true - # #headless_chrome_path: headless-chromium - # # - - # #enabled_if_env: ENABLE_PDF_EXPORT - # # See notes at the top of templates/styles.scss - # # for debugging workflow details. - # debug_html: true - # #show_anchors: true + - with-pdf: + # Generate the whole site as a single PDF + # Full details on this plugin here: + # https://github.com/orzih/mkdocs-with-pdf + # And don't get it confused with https://github.com/zhaoterryy/mkdocs-pdf-export-plugin + # which is intended to export a single page at a time + output_path: ../pdfs/QGISAnimationWorkbench.pdf + author: Tim Sutton, Nyall Dawson + # copyright will draw in page.bottom-right + # do it manually in templates/styles.scss + # for more control + # if you comment out here or use an empty string, + # the copyright text from mkdocs-base.yml will be + # used instead + copyright: ' ' + cover: true # see templates/cover.html + back_cover: true + cover_title: The QGIS Animation Workbench + cover_subtitle: Bring your QGIS maps to life! + cover_logo: ../resources/img/logo/animation-workbench-logo.svg + # Print css is defined in templates/styles.scss + #custom_template_path: TEMPLATES PATH + # + toc_title: Contents + #heading_shift: false + # Set to 0 so that it does not generate chapter numbering + # we do the numbering in styles.css rather + toc_level: 0 + ordered_chapter_level: 0 + #excludes_children: + # - 'release-notes/:upgrading' + # - 'release-notes/:changelog' + # + #exclude_pages: + # - 'bugs/' + # - 'appendix/contribute/' + #convert_iframe: + # - src: IFRAME SRC + # img: POSTER IMAGE URL + # text: ALTERNATE TEXT + # - src: ... + #two_columns_level: 3 + # + #render_js: true + #headless_chrome_path: headless-chromium + # + + #enabled_if_env: ENABLE_PDF_EXPORT + # See notes at the top of templates/styles.scss + # for debugging workflow details. + debug_html: true + #show_anchors: true diff --git a/docs/pdfs/QGISAnimationWorkbench.pdf b/docs/pdfs/QGISAnimationWorkbench.pdf index 64b8322..e3ba37b 100644 Binary files a/docs/pdfs/QGISAnimationWorkbench.pdf and b/docs/pdfs/QGISAnimationWorkbench.pdf differ diff --git a/docs/requirements.txt b/docs/requirements.txt index 95a0b3e..bffe47d 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,8 +1,9 @@ #Alternative for pdf creation - broken on nixos and lately ubuntu -#mkdocs-with-pdf +mkdocs-with-pdf # Export to pdf - see https://comwes.github.io/mkpdfs-mkdocs-plugin/index.html -mkpdfs-mkdocs - +#mkpdfs-mkdocs +# Rather do +# pip install -e git+https://github.com/jwaschkau/mkpdfs-mkdocs-plugin.git#egg=mkpdfs-mkdocs mkdocs-material mdx_gh_links mkdocs-pdf-export-plugin @@ -15,3 +16,4 @@ mkdocs-git-revision-date-localized-plugin shortuuid # Needed for mkdocstrings python documentation generator black +cffi diff --git a/docs/src/tutorials/tutorial5.md b/docs/src/tutorials/tutorial5.md index 4209f56..20c54a2 100644 --- a/docs/src/tutorials/tutorial5.md +++ b/docs/src/tutorials/tutorial5.md @@ -266,7 +266,10 @@ if ( ## Final Render -There are still a few details that would need to be taken care of to reach a final solution - in particular taking care of datelines and the like. Buhere is a little example of what we managed to make thus far (without any debugging text). +There are still a few details that would need to be taken care of to reach a +final solution - in particular taking care of datelines and the like. But here is +a little example of what we managed to make thus far (without any debugging +text). ![](img/tut_5/planar_map_final.gif) diff --git a/docs/templates/styles.scss b/docs/templates/styles.scss index 8c3dc00..751233b 100644 --- a/docs/templates/styles.scss +++ b/docs/templates/styles.scss @@ -412,4 +412,9 @@ ul, ol, dl { page-break-before: avoid; -} \ No newline at end of file +} + +.external-link::after { + content: " (" attr(href) ")"; + font-style: italic; +} diff --git a/docs/templates/styles.scss.templ b/docs/templates/styles.scss.templ index b6ee72f..e7a3e9f 100644 --- a/docs/templates/styles.scss.templ +++ b/docs/templates/styles.scss.templ @@ -412,4 +412,9 @@ ul, ol, dl { page-break-before: avoid; -} \ No newline at end of file +} + +.external-link::after { + content: " (" attr(href) ")"; + font-style: italic; +}