Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

icon styles: svgSymbols / svg_templates #1193

Open
dbauszus-glx opened this issue Mar 21, 2024 · 2 comments · May be fixed by #1344
Open

icon styles: svgSymbols / svg_templates #1193

dbauszus-glx opened this issue Mar 21, 2024 · 2 comments · May be fixed by #1344
Assignees
Labels
Feature New feature requests or changes to the behaviour or look of existing application features. RFC Request for Comment or Change.

Comments

@dbauszus-glx
Copy link
Member

The svgSymbols mapp mod has become quite a long in the teeth.

The type icons should be retired once the styleParser has been reviewed and merged.

There are currently following type symbols.

dot
target
triangle
square
diamond
semiCircle
markerLetter
markerColor
circle
template

SVG icons hosted in the public directory should be made available for these.

The styleParser method can replace the type declarations with the matching svg.

It must still be possible to create an icon from a custom function. Memoization is crucial is this is to happen inside the theme method.

The template type icons should be created with the styleParser.

@dbauszus-glx dbauszus-glx added the Feature New feature requests or changes to the behaviour or look of existing application features. label Mar 21, 2024
@dbauszus-glx dbauszus-glx changed the title svgSymbols svgSymbols / svg_templates May 3, 2024
@dbauszus-glx
Copy link
Member Author

The svg_templates plugin method shouldn't be a plugin method. This method should always be executed when a mapview is created. But svg_templates should not be loaded twice in the case of multiple mapviews in a document.

With the svgSymbols being retired it doesn't make sense to have the type: template if there is only a single type.

It must still be possible to create a custom templates from a function.

There should be an interface to define custom templates and colour substitutes.

The templates should render without any colours being substituted.

@dbauszus-glx dbauszus-glx changed the title svgSymbols / svg_templates icon styles: svgSymbols / svg_templates Jun 21, 2024
@dbauszus-glx dbauszus-glx added the RFC Request for Comment or Change. label Jun 21, 2024
@dbauszus-glx
Copy link
Member Author

The next step will be to create svg templates for each type.

These default templates could be imported as string from svg files in the public folder if possible.

The target: type needs to be translated into base icon dot (with shadow) and additional icon array items which do not have a shadow.

A translation method will be required for each of the type icons.

It may be necessary to flatten icon arrays where an array type target is in an icon array.

@dbauszus-glx dbauszus-glx linked a pull request Jun 21, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New feature requests or changes to the behaviour or look of existing application features. RFC Request for Comment or Change.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants