summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Add Makefile.in files to .gitignorewip/sophie-h/workspaceFederico Mena Quintero2023-04-251-0/+5
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Copy a utility function to the librsvg-c tests to avoid having a test-utils ↵Federico Mena Quintero2023-04-252-3/+9
| | | | | | | | | | | feature The only thing that librsvg-c's tests use from rsvg::test_utils is the load_svg() function. That function is trivial enough that we can just copy it to librsvg-c's tests, and thus avoid having a whole feature specification just for that. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* c-api: Move test utils dep to dev-dependenciesSophie Herold2023-04-251-0/+2
| | | | | | It was (probably by accident) under build-dependencies before Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* ci/gen-coverage.sh: Remove the --prefix-dir option for grcovFederico Mena Quintero2023-04-241-2/+0
| | | | | | | Now that C files are scattered around, we'll just let grcov warn about their paths which contain "../". Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* gen-coverage.sh: No need to ignore build.rs anymoreFederico Mena Quintero2023-04-241-2/+0
| | | | | | | Now that https://github.com/mozilla/grcov/issues/845 is fixed, we can remove the workaround. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: don't use after_script for the coverage job; put everything in the same ↵Federico Mena Quintero2023-04-241-2/+0
| | | | | | script Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* ci/build-with-coverage.sh: Adjust for clang 16Federico Mena Quintero2023-04-241-3/+12
| | | | | | | | | With clang 15.0.7, its utility libraries were in /usr/lib64/clang/15.0.7/lib/linux. However, with clang 16, they are now in /usr/lib64/clang/16/lib/linux (e.g. without minor/micro version numbers). Extract just the major version from `clang --version`. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: use the latest version of python3-docutils, not specificially 3.8Federico Mena Quintero2023-04-211-1/+1
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: use the correct path for the coverage profilesFederico Mena Quintero2023-04-211-1/+1
| | | | | | | They were being written to ./rsvg/coverage-profiles instead of ./coverage-profiles, which is what the gen-coverage.sh script expects. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Use helper functions and call them from the macros for test referencesFederico Mena Quintero2023-04-213-75/+94
| | | | | | Avoids generating lots of duplicated code in tests. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: install diffutils and findutilsFederico Mena Quintero2023-04-211-1/+3
| | | | | | autotools requires them, it seems, but it has worked so far...? Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* devel-docs/architecture.rst: Fix the paths for the C APIFederico Mena Quintero2023-04-211-7/+8
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: Generate internals docs for the whole workspaceFederico Mena Quintero2023-04-211-2/+2
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Fix warnings from "cargo doc"Federico Mena Quintero2023-04-219-25/+25
| | | | | | A bunch of unquoted http links and XML element names, mostly. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* docs: fix item nameFederico Mena Quintero2023-04-211-1/+1
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* cargo fmtFederico Mena Quintero2023-04-211-6/+3
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* rsvg-convert/tests/fixtures - Copy the few fixtures we need hereFederico Mena Quintero2023-04-2125-99/+158
| | | | | | | | | | Do not use a symlink; automake doesn't understand them for distcheck. The fixtures that are duplicated from rsvg/tests/fixtures are just a few, and they are small. I prefer having rsvg-convert's fixtures in a single place instead of referencing something like ../../blahblah. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Makefile.am: fix paths for the sources in the rsvg crate testsFederico Mena Quintero2023-04-211-13/+13
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* test-utils.c: Fix path to fixturesFederico Mena Quintero2023-04-211-1/+1
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Fix documentation exampleFederico Mena Quintero2023-04-211-1/+2
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: remove the test_rust_gdk_pixbuf_loader job, it's implied by --workspace nowFederico Mena Quintero2023-04-211-18/+0
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* CI: use "cargo test --workspace" everywhere to test all the projectsFederico Mena Quintero2023-04-211-3/+3
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Move rsvg/tests/src/*.rs to rsvg/tests/*.rsFederico Mena Quintero2023-04-2113-0/+0
| | | | | | Otherwise cargo doesn't pick them up as tests. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* gdk-pixbuf-loader: fix module pathFederico Mena Quintero2023-04-211-1/+1
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* NMake Makefiles: Correct paths for C testsChun-wei Fan2023-04-211-2/+2
| | | | | | The C tests were moved to librsvg-c/tests-c, so update things accordingly Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Use tinyvec's rustc_1_55 feature to reduce compilation timeFederico Mena Quintero2023-04-201-1/+1
| | | | | | | | | | | | | | | | | | | While casually reading https://hackmd.io/mxdn4U58Su-UQXwzOHpHag (Analysis of rustc-benchmarking-data), I noticed that it mentions https://github.com/Lokathor/tinyvec/issues/161. The tinyvec crate, with the default set of features, can compile on rustc < 1.55 by using large implementations of Default for [T; N]. On Rustc >= 1.55, it can elide this code and just use const generics. Apparently this reduces compilation time for tinyvec by about half - which is not a lot in the context of librsvg, but let's make use of that. Librsvg currently requires Rust >= 1.64.0 anyway, so we can make use of tinyvec's rustc_1_55 feature. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* autotools: distribute the gdk-pixbuf-loader Rust sourcesFederico Mena Quintero2023-04-191-0/+2
| | | | | | | Even though they are not part of the autotools build yet, they do get referenced in the Cargo workspace. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* The tests README.md is no longer in librsvg-c/tests-cFederico Mena Quintero2023-04-191-4/+0
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* autotools: fix paths of Rust test sourcesFederico Mena Quintero2023-04-192-76/+72
| | | | | | Autotools doesn't use them except for making release tarballs. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Makefile.am: fix paths of the benches sourcesFederico Mena Quintero2023-04-191-10/+10
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Fix module name in gdk-pixbuf-loaderFederico Mena Quintero2023-04-191-1/+1
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Rename README.rst back to rsvg-convert.rstFederico Mena Quintero2023-04-191-0/+0
| | | | | | Seems like it was inadvertently renamed. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* autotools: Make rsvg-convert buildFederico Mena Quintero2023-04-193-4/+3
| | | | | | | | | * Rename the librsvg-c project's library back to "librsvg_c". Rust will then build target/whatever/liblibrsvg_c.a. * Build librsvg_c as an rlib too, so rsvg-convert can use it. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Makefile.am: list the rsvg-convert sources, and build just that packageFederico Mena Quintero2023-04-191-2/+6
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Makefile.am: build just the librsvg-c package for the C ABI libraryFederico Mena Quintero2023-04-193-3/+6
| | | | | | Also, change the crate-type to staticlib in librsvg-c as it was before. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Makefile.am: Fix the source paths for the C ABI libraryFederico Mena Quintero2023-04-191-91/+94
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Move librsvg-c/src/c_api/* one directory upFederico Mena Quintero2023-04-198-60/+59
| | | | | | | | | librsvg-c/src/lib.rs just had "pub mod c_api;", so let's pull everything one directory up. This will also make it slightly easier to fix the toplevel Makefile.am. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* autotools: the C tests got moved to librsvg-c/tests-cFederico Mena Quintero2023-04-192-2/+2
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* meta: Separate C API from rust crateSophie Herold2023-04-0144-288/+161
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* meta: Naive move of c_api to own crateSophie Herold2023-04-0112-4/+165
| | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* NMake Makefiles: Update source pathsChun-wei Fan2023-03-311-2/+2
| | | | | | The NMake Makefiles need a small update so that the test sources can be located Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* meta: Move lib and bins into separate cratesSophie Herold2023-03-311776-2170/+254
| | | | | | Closes #950 Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/822>
* Merge branch 'unify-viewport' into 'main'Marge Bot2023-03-3015-300/+343
|\ | | | | | | | | Remove the current viewport as mutable state from DrawingCtx See merge request GNOME/librsvg!821
| * render_tree.rst: Updates from todayFederico Mena Quintero2023-03-301-5/+16
| | | | | | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/821>
| * Remove the viewport_stack; it is unused nowFederico Mena Quintero2023-03-301-28/+1
| | | | | | | | | | | | The actual viewport stack is now implied as arguments in the call stack. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/821>
| * Pass the current Viewport around as arguments to the drawing functionsFederico Mena Quintero2023-03-309-194/+239
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - All the drawing functions get a new argument of type &Viewport. The idea is that the caller computes a new Viewport and just passes a reference to it. The viewport stack is implied by the call stack, instead of being represented as mutable state in DrawingCtx. This removes DrawingCtx::get_viewport() and ::get_top_viewport(). - Rename Svg::push_viewport() to make_svg_viewport(). - Remove DrawingCtx::get_viewport_for_units(); replace it with Viewport::from_units(). - Remove DrawingCtx::push_coord_units(), which was just being called in generate_cairo_mask() - this takes care of the TODO that mentioned exactly that goal. - Remove DrawingCtx::push_view_box(); replace it with Viewport::with_view_box(). Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/821>
| * Combine ViewParams and Viewport into a single struct ViewportFederico Mena Quintero2023-03-3012-156/+170
|/ | | | | | | | | | | | | | | | | | | | | ViewParams was the original set of values that we used since 2018 for length normalization. Viewport was my attempt to start unifying the "viewport" concept, around 2020 and #298. My current plan is to remove the current viewport from the mutable part of DrawingCtx, and instead pass the current viewport as function arguments to the draw() functions. This commit basically moves the fields and methods from ViewParams into Viewport, and makes everything use Viewport instead of ViewParams. Things are a bit funky because of the viewport_stack field, which is shared via an Option<Weak<>> to the viewport stack in the DrawingCtx - but that will disappear when the current viewport is passed as arguments instead of mutable state. Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/821>
* Merge branch 'update-container-image' into 'main'Marge Bot2023-03-307-56/+8
|\ | | | | | | | | CI: bump the container image See merge request GNOME/librsvg!817
| * clippy: Use derivable impls for enumsFederico Mena Quintero2023-03-302-15/+5
| | | | | | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/817>
| * CI: Update the Rust stable version to 1.68.2Federico Mena Quintero2023-03-301-2/+2
| | | | | | | | Part-of: <https://gitlab.gnome.org/GNOME/librsvg/-/merge_requests/817>