Repository navigation
Description
Tracking issue for opening QGIS projects and styles in RustGIS as QGIS draws them. Each piece below gets its own pull request, or a few (piece 1 had a proposal issue, #883; with the plan agreed, the later pieces go straight to pull requests); this issue keeps the order and links them.
Where it stands
- Merged: feat(map): open QGIS projects as maps and apply QGIS layer styles #825 (
project.importQgis,style.importQgis), feat(labels): draw labels in an installed font family, by name #824 (label fonts), fix(map): QGIS import follow-ups: TRUE/FALSE and exponents in filters, label fonts, unread source options #844 (filters, fonts, source notes), feat(map): QGIS import reads merged categories, dashes and QGIS 1/2 names, and notes what it drops #876 (merged categories, dashes, QGIS 1.8/2.x names, notes for everything dropped), feat(map): QGIS import colours rasters as QGIS does, and QGIS raster styles apply to rasters #877 (raster renderers), test(map): a corpus of QGIS projects and styles the importer reads #881 (the test corpus: 90 generated styles and 21 generated projects), feat(map): QGIS projects in degrees open in Equirectangular, as QGIS draws them #885 (piece 1), feat(map): markers and hash marks along lines, as QGIS's marker and hashed lines draw them #900 (piece 2), feat(map): a character of a font as a marker, as QGIS's font markers draw one #926 (piece 3a), fix(render): slanted label letters are solid, without stripes #927 (stripes across large hand-slanted italic labels), feat(map): a point's marks stacked, shifted and turned, and markers turned by a field #933 (piece 3b), feat(labels): a halo's own colour and width, and letter spacing, as QGIS's buffer and spacing #964 (piece 4a), feat(labels): a label's offset and background, as QGIS's offset from a point and its rectangle background #1007 (piece 4b, first part: offsets and backgrounds), feat(labels): wrapping and repeat along lines, as QGIS's wrap and repeat distance #1014 (piece 4b, second part: wrapping and repeat along lines), feat(symbology): stacked polygon fills — hatch lines and markers, from QGIS fill symbols (#882 piece 5a) #1022 (piece 5a: stacked fills, hatch lines and markers), feat(symbology): gradient and shapeburst polygon fills, from QGIS fill symbols (#882 piece 5b) #1104 (piece 5b: gradient and shapeburst fills; QGIS 3's line pattern angle, which was always drawn at 45°) with its follow-up fix(render): a thin shapeburst's tiles stop at the frame's budget #1114, feat(data): an expression language for queries and Calculate Field (#882 pieces 6+7, part 1) #1164 (pieces 6 and 7, part 1: the expression language, used by queries and Calculate Field), feat(symbology): symbol size, colours, outline width and angle by expression (#882 pieces 6+7, part 2) #1185 (part 2: symbol size, colours, outline width and angle by expression, also from QGIS's data-defined settings), feat(labels): label text, size, colour and angle by expression (#882 pieces 6+7, part 3) #1309 (part 3: label text, size, colour and angle by expression), feat(style): Unique Values by expression; QGIS rule-based renderers and filters through expressions (#882 pieces 6+7, part 4) #1314 (part 4: Unique Values by expression; QGIS rule-based renderers and filters through expressions), feat(qgis): categorized renderers by an expression as Unique Values by expression (#882) #1421 (a follow-up to pieces 6 and 7: QGIS categorized renderers by an expression as Unique Values by expression; filters withCASEorBETWEENno longer read as field names), feat(qgis): pie diagrams carry over from QGIS projects and styles (#882) #1691 (piece 13, first part: QGIS pie diagrams as RustGIS pie diagrams; histograms, stacked bars and text diagrams noted), feat(qgis): annotation layers carry over as graphics layers (#882) #1790 (piece 13, second part: QGIS annotation layers as graphics layers, with a 22nd generated project in the corpus; also fixes QGIS 4's normal-weight labels coming in bold), feat(qgis): the layer tree's groups carry over as nested layer groups (#882) #1836 (piece 11, first part: the layer tree's groups as nested layer groups, open or closed, each layer with its own box, a group layer's opacity and visibility range on its group, QGIS 2's legend groups too; mutually exclusive groups, group layers' blending and effects, a custom layer order, the legend's own drawing order and groups past RustGIS's limits (8 levels, 2,000 groups) noted; also reads layers' blending modes by QGIS's own numbers, which drew Multiply as Normal; a 23rd generated project), feat(qgis): bookmarks, relations, the map's rotation and layers' time carry over (#882) #1847 (piece 11, second part: bookmarks at their places, turned as QGIS turns them; relations as relationships; the map's rotation; layers' time from a date field bound to the time slider, left off as QGIS opens a project; bookmark groups, polymorphic relations, the project's time span and time from expressions or fixed ranges noted; a 24th generated project), feat(qgis): vector tile archives, GPX, memory and virtual layers come in; database tables name a saved connection (#882 piece 10a) #2354 (piece 10, first part: QGIS 4's vector tile providers, which were all left out, as tile layers from their address, an MBTiles file or a PMTiles archive, their QGIS style noted; GPX waypoints, routes or tracks; memory layers empty with their fields, as QGIS opens them; virtual layers that select from one layer as that layer with its filter, other queries noted; PostGIS and SQL Server tables noted with a saved connection to log in to, made without the password; 7 more generated projects, 31 in all), feat(map): QGIS projects' web service layers come in from their services (#882 piece 10b) #2471 (piece 10, second part: WFS, OGC API Features, ArcGIS feature, map, image and vector tile services and WCS through the service commands, as Add Web Data adds them; WMTS layers asked as WMTS; logins and unread settings noted; 5 more generated projects, 36 in all), feat(engine): import a QGIS project off the window, with progress and Cancel #3120 (the follow-up QGIS project import runs off the window, with progress and Cancel #2476:project.importQgisoff the window on the desktop, its file read and parsed on a thread of its own, then the import run on a copy of the session with progress and Cancel; saved logins its services need opened first and borrowed by the copy), feat(qgis): import a QGIS project's print layouts as layouts (piece 12a) #3438 (piece 12a: QGIS print layouts as RustGIS layouts, each page a layout of its own: pages and their papers, map items as frames showing the imported map at their extent, scale and turn, labels with their font, alignment, margins, background and expressions as RustGIS's tokens, pictures, rectangles, ellipses, lines and polygons; scale bars, north arrows, legends, tables, HTML, grids, overviews and the atlas noted; a 39th generated project). - Underway: piece 9's image markers, by jgregoriorincon under [Feature]: Picture markers: a PNG, JPEG or SVG image as a point's marker #2266: PNG and JPEG markers on points, in stacked marks, along lines and in dot fills, with previews and exports (feat(map, render, engine): a PNG or JPEG image as a point's marker (#2266 part A1) #2278, fix(engine, map): a map package's map file requires what it draws, and an image's dots show in a feature of no fill (#2266) #2300, feat(engine, render, ui): an image as a line's markers and a dot fill's marker (#2266 part A2a) #2366, fix(render): picture markers take PNG or JPEG alone; an empty image is refused (#2266) #2423, feat(ui): previews show picture markers' images (#2266) #2449, feat(render): a picture marker is one image in a PDF or SVG; a line's markers and shifted strokes show from off the view (#2266) #2477, feat(ui): Image… in the marker menus picks a PNG or JPEG file as a symbol's, mark's or dot fill's marker (#2266) #2554); ArcGIS layers' picture markers (feat(map, engine): an ArcGIS layer's picture markers draw the service's own images (#2266 part C) #2588); QGIS's
RasterMarkerwith its own image (feat(map, engine): a QGIS raster image marker draws its own image (#2266 part D) #2612); SVG images as markers (Picture markers take SVG images, bounded in reading and drawing (#2266 part E1a) #2704, feat(symbology): Image… lists SVG files, and an SVG marker image requires svg-markers (#2266 part E1b) #2854); QGIS'sSvgMarkerdrawing its own SVG (feat(map): a QGIS SVG marker draws its own SVG (#2266 part E2a) #3091, with corpus files in test(map): SVG markers in the QGIS corpus (#2266 part E2c) #3051) and taking its layer's fill and outline colours (feat(map, engine): a QGIS SVG marker takes its layer's colours #3223). Left in piece 9: arrows and draw effects, not started. - Underway: piece 12, print layouts, by pick2510, in three parts (plan in the comments): 12a pages, map frames, text, pictures, shapes and lines (merged, feat(qgis): import a QGIS project's print layouts as layouts (piece 12a) #3438); 12b scale bars, north arrows and legends, in two parts: scale bars, north arrows and map overviews (PR open, QGIS import: print layouts' scale bars, north arrows and map overviews (piece 12b of #882) #3556), then legends and map grids; 12c attribute tables and the atlas as a map series.
- Order from here (re-checked 2026-11-25, by value for cost; see the note under the table): 9 (underway, above), 12, 8, 14.
- Audit: 149 files: the corpus of test(map): a corpus of QGIS projects and styles the importer reads #881, the QGIS Training Manual and swisstopo's SMV25. They all import without a crash. Every setting is now read, noted as approximated or left out, or ignored as irrelevant to the map, except 72 project-structure details.
- Why SMV25: SMV25 serves only as a large, demanding real-world QGIS project: 66 layers and about 2,000 symbol layers combining categorized renderers, dashes, markers along lines, font markers, pattern fills, rule-based labels and data-defined settings. It uses a handful of QGIS's features heavily rather than many of them; the generated files cover the breadth. Its Swiss data isn't the goal. It isn't in the repository (no third-party vendor styles); the corpus README links its download, and comparisons on it are run locally.
- Measure: SMV25 rendered by RustGIS and by QGIS 4.2.3 at the same extent: 7.2 % of pixels differ in Winterthur's old town (1.8 × 1.1 km), 11.0 % in an overview around it (7.2 × 5.1 km). With feat(map): a character of a font as a marker, as QGIS's font markers draw one #926: 6.8 % and 10.9 %. With feat(labels): a halo's own colour and width, and letter spacing, as QGIS's buffer and spacing #964: 8.3 % and 10.9 % (a forest view of the same size: 3.4 % → 4.1 %). The old town got worse because QGIS draws no place-name labels at 1 m/px while RustGIS does, and those now carry their 0.5 mm halo. On main of 2026-11-04 (pieces 5 to 7 merged): 8.1 % and 11.0 % (forest 4.1 %), unchanged since feat(symbology): gradient and shapeburst polygon fills, from QGIS fill symbols (#882 piece 5b) #1104: SMV25 uses few data-defined settings or rule styles, and its fills were already drawn. Not measured again since: feat(qgis): categorized renderers by an expression as Unique Values by expression (#882) #1421, feat(qgis): pie diagrams carry over from QGIS projects and styles (#882) #1691 and feat(qgis): annotation layers carry over as graphics layers (#882) #1790 cover settings SMV25 doesn't use.
The pieces
Ordered by how often real projects (SMV25 and the Training Manual) hit them, and whether RustGIS already has the feature. Mapping means the importer reads QGIS's setting into something RustGIS has; feature means RustGIS needs it first.
| # | Piece | Kind | Crates | Size |
|---|---|---|---|---|
| 1 | #883, #885 Geographic coordinate systems: a project in EPSG:4326 (9 of the real projects) opens in Equirectangular instead of Web Mercator, as QGIS draws it | mapping | engine | small |
| 2 | #900 Markers along lines and hash lines: interval, placement (vertices, first/last, centre), rotation with the line (SMV25: railways, boundaries) | feature | map, render | medium |
| 3 | Font markers: a character from a font as a point symbol, with rotation (SMV25: 12 layers of map signs). 3a #926: the character, on points and along lines. 3b #933: several marks stacked on a point (half of SMV25's signs are a white character under a coloured one), their offsets, and rotation by a field (SMV25: - "WINKEL") |
feature | map, render | medium |
| 4 | Labels. 4a #964: halo colour and width, letter spacing (SMV25: 129 of 140 label classes have a 0.5 mm white halo, 31 use letter spacing). 4b: offsets from a point and backgrounds (#1007), then wrapping and repeat along lines (#1014), both merged, as plain label settings that #995 (a label engine with candidate positions; its part 1a, other positions round a point, is #1025, merged) builds on; the distance from a line goes to #995's step 2 | feature | map, render | large |
| 5 | Fills. 5a #1022: several fills per symbol (and per class), the line brushes and line pattern fills as hatch lines, point pattern fills as markers on a grid (SMV25: 296 simple fills, 6 line and 5 point pattern fills, 18 symbols of two or three fill layers). 5b #1104: gradient (linear, radial, conical) and shapeburst fills, with their colour ramps | feature | map, render | medium |
| 6 | Data-defined properties: size, colour, rotation by field, on symbols and labels. One track with piece 7, expressions first (a field is the simplest expression): part 2 #1185 (merged): symbol size, colours, outline width and angle by expression, QGIS's data-defined symbol settings carried over; part 3 #1309 (merged): label text, size, colour and angle by expression, QGIS's label text expressions and data-defined label settings carried over | feature | map, render | medium |
| 7 | Expressions: an expression language for feature layers (arithmetic, functions, CASE) for filters, label text and data-defined values; QGIS expressions translated to it. Part 1 #1164 (merged): the language, grown from the WHERE clause language (every clause selects the same rows), used by queries and Calculate Field; part 4 #1314 (merged): Unique Values by expression, the importer's filters and rule-based renderers through it |
feature | data, map | large |
| 8 | Renderers: rule-based renderers beyond the SQL subset (came with #1314, as Unique Values by expression); left: inverted polygons, merged features, heat maps, none of which RustGIS draws yet (SMV25 uses none) | feature | map, render | medium |
| 9 | Symbols: SVG and image markers on feature layers, arrows, draw effects (shadow, glow). RustGIS's markers are still shapes and font characters; the largest drawing gap left for SMV25 (its line-end pictures and SVG signs). Image markers under #2266 (RasterMarker merged in #2612, SvgMarker in #3091 and #3223); arrows and draw effects not started |
feature | map, render | large |
| 10 | Sources: SpatiaLite, SQL Server, ArcGIS feature and map servers, WCS, vector tiles, delimited text with WKT, memory layers with their features, virtual layers through sql.query. RustGIS now reads SQL Server and ArcGIS FeatureServer, MapServer and WCS services. 10a #2354 (merged): vector tiles (MBTiles, PMTiles, QGIS 4's providers), GPX, memory and virtual layers, database tables with a saved connection; 10b #2471 (merged): the web services |
mapping | engine, map | medium |
| 11 | Project structure: groups (opacity, scale range), bookmarks, time settings, relations; notes for map themes, variables, joins, virtual fields. RustGIS now has all four: nested groups with opacity and scale range (#1102), bookmarks, time settings (time.*) and relations (data.relate); groups: #1836 (merged); bookmarks, time settings and relations: #1847 (merged). Map themes, saved joins and virtual fields have no RustGIS equivalent yet and stay notes |
mapping | engine, map | medium |
| 12 | Print layouts: QGIS layout items, page sizes, map item extent, scale and theme, the atlas, onto RustGIS layouts (the atlas onto a layout's map series) | mapping | engine, map | large |
| 13 | Annotations and diagrams: the QGIS annotation layer as a graphics layer; per-feature diagrams (RustGIS draws pie and bar diagrams since #1048, so these are now a mapping). Diagrams: #1691 (merged), pies carried over, histograms, stacked bars and text diagrams noted. Annotations (13b): onto RustGIS's graphics layers (text, shapes, pictures): #1790 (merged) | mapping | engine, map | medium |
| 14 | Round trip: project.exportQgis and style.exportQgis, tested by reading back |
feature | map, engine | large |
Order from here. The table keeps its numbers (pull requests refer to them), but RustGIS has since gained what 10, 11, 12 and 13b map onto, so they are now importer work only. They go first, cheapest and most common first: 13b (annotations, merged with #1790), 11 (project structure: every project has groups), 10 (sources). Then 9 (symbols: the largest drawing gain for SMV25), 12 (layouts, large), 8 (renderers RustGIS lacks, rare in the real projects) and 14 (export).
Related but separate: #769 (WMTS tile matrix sets other than Web Mercator, now closed; WMS and WMTS layers in other coordinate systems came with #1127) affects QGIS projects only through their WMTS and tile layers. #1102 (nested layer groups) lets piece 11 carry QGIS's group tree over as it is, rather than flattened.
How each piece is tested
- Unit tests: in
crates/map/src/qgis/tests.rs, written in the shapes QGIS writes, for each setting read. - Corpus:
every_corpus_file_readsovercrates/map/testdata/qgis/(test(map): a corpus of QGIS projects and styles the importer reads #881). A piece that needs a setting the corpus lacks adds a file throughgenerate.py. - Engine tests: for the commands (
project.importQgis,style.importQgis), includinghostile_params_never_panic. - Rendering pieces (2–9): a render test in
crates/render, plus a comparison with QGIS on SMV25 (downloaded, not in the repository) at fixed extents reported in the pull request (the pixel difference before and after).
Not planned
Mesh, point cloud and tiled-scene layers (no RustGIS equivalent), 3D views, layer actions, forms and editing widgets: noted on import.
Pieces 1 to 7, 10, 11 and 13 are merged (10: #2354 and #2471; 11: groups in #1836, bookmarks, relations, rotation and time in #1847; 13: diagrams in #1691, annotations in #1790); the pull requests are listed under Where it stands.
Activity
pick2510 commentedon Oct 25, 2026
@giswqs Any comments on this plan, the order or the scope? Piece 1 is proposed in #883 and implemented as a draft in #885; I'll mark it ready once you're fine with the approach.
giswqs commentedon Oct 25, 2026
@pick2510 This is a great plan! Thank you for putting it together. Just added you to the RustGIS-Maintainers team. Keep going.
pick2510 commentedon Oct 25, 2026
Great. I will continue with the stepwise implementation.
feat(map): markers and hash marks along lines, as QGIS's marker and h…
feat(map): a character of a font as a marker, as QGIS's font markers …
feat(map): a character of a font as a marker, as QGIS's font markers …
feat(map): a point's marks stacked, shifted and turned, and markers t…
feat(labels): a label's offset and background, as QGIS's offset from …
feat(labels): wrapping and repeat along lines, as QGIS's wrap and rep…
feat(symbology): stacked polygon fills with hatch lines and markers, …
feat(symbology): stacked polygon fills — hatch lines and markers, fro…
feat(symbology): gradient and shapeburst polygon fills, from QGIS fil…
feat(data): an expression language for queries and Calculate Field (#882
feat(symbology): symbol size, colours, outline width and angle by exp…
38 remaining items
fix(qgis): a virtual layer's own filter (subsetstring) kept, a tile a…
fix(qgis): a database table's filter (sql=) named among the settings …
fix(qgis): a filter's note says where it came from, a memory layer's …
fix(qgis): a virtual layer on a multi-layer file named without a laye…
fix(qgis): a virtual layer on a project layer of a multi-layer file n…
fix(qgis): network-share archive paths refused before the file is loo…
feat(qgis): vector tile archives, GPX, memory and virtual layers come…
fix(map): QGIS web service notes count every option and never name a …
feat(map): QGIS projects' web service layers come in from their servi…
pick2510 commentedon Nov 30, 2026
Piece 12: print layouts — plan
Today a project's layouts are noted as left out (
its print layouts (n)). RustGIS already has what they map onto (layouts with map frames, text, pictures, scale bars, north arrows, legends, tables, shapes, lines and a map series), so this is importer work: each QGIS layout comes in as a RustGIS layout of the project, its map frames showing the map the import makes. What can't be carried over is noted per layout and item kind, with a count.12a: pages and the items that stand alone
[% … %]expressions as RustGIS's tokens where one matches (title, date, scale), otherwise kept as text and noted.12b: surrounds tied to a map: scale bars (units, segments, style, label size), north arrows (QGIS's north-arrow picture following a map), legends (title, columns, the layers it lists and their labels), map grids, overviews.
12c: tables and the atlas: attribute tables as tables of the layer they name; the atlas as a map series (the coverage layer, the page name from a field, the margin), noting what a map series doesn't do (sorting, filtering, expressions beyond a field).
Testing: unit tests in the shapes QGIS writes; new generated projects from
generate.py(an A4 map sheet, items in each unit, rotated and grouped items, several pages, an atlas); engine tests forproject.importQgis; and each part's layouts rendered beside QGIS's own export of them, the pixel difference reported in the pull request.The import itself: layouts land with the map. Their frames name the map by its final name (when a map of that name exists, the imported one is renamed,
Title2), and Undo removes both.fix(map): QGIS layouts: a label's own braces as parentheses; @project…
fix(map): QGIS layouts: pages and written-out titles bounded over the…
fix(qgis): layout names written out within the import's budget; pictu…
feat(qgis): import a QGIS project's print layouts as layouts (piece 1…
QGIS import: print layouts' scale bars, north arrows and map overview…