Skip to content
This repository has been archived by the owner on Mar 8, 2023. It is now read-only.

HARP-12677: Extract PoiRenderer from TextCanvas #1994

Merged
merged 13 commits into from
Dec 3, 2020
Merged

Conversation

FraukeF
Copy link
Contributor

@FraukeF FraukeF commented Nov 27, 2020

  • Makes PoiRenderer independent from TextCanvas
  • PoiRenderer renders on its own
  • Icons can be rendered even if no FontCatalog is availble

Signed-off-by: Frauke Fritz frauke.fritz@here.com

Thank you for contributing to harp.gl!

Before requesting a pull request, please remember to check the following documents:

If you are adding new functionality we would highly appreciate if you can describe what is the capability you are adding and even better if you can add some examples. Please also remember to add tests for it.

CI Check

Our bots will check whether your PR can be directly integrated into the mainline. We have some internal integration tests running on the background, our bots will inform you of the next steps and someone from our team will take a look and help if needed!

And please do not forget to sign-off your commit! You can read more about DCO here. But, in short, you just need to use git commit -s or append --signoff when you are committing to the repo.

Happy contributing!

@FraukeF
Copy link
Contributor Author

FraukeF commented Nov 27, 2020

@harpgl-bot retest this please

@codecov
Copy link

codecov bot commented Nov 27, 2020

Codecov Report

Merging #1994 (ea961cd) into master (1ee9ff7) will decrease coverage by 0.02%.
The diff coverage is 50.72%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1994      +/-   ##
==========================================
- Coverage   66.16%   66.14%   -0.03%     
==========================================
  Files         295      294       -1     
  Lines       26294    26299       +5     
  Branches     5909     5909              
==========================================
- Hits        17398    17395       -3     
- Misses       8896     8904       +8     
Impacted Files Coverage Δ
@here/harp-text-canvas/lib/TextCanvas.ts 66.25% <11.11%> (-0.99%) ⬇️
@here/harp-mapview/lib/text/FontCatalogLoader.ts 80.00% <33.33%> (-5.72%) ⬇️
@here/harp-mapview/lib/poi/PoiRenderer.ts 41.02% <38.46%> (-3.34%) ⬇️
...here/harp-mapview/lib/text/TextElementsRenderer.ts 69.14% <56.36%> (-0.71%) ⬇️
@here/harp-mapview/lib/text/TextStyleCache.ts 54.88% <85.71%> (+3.12%) ⬆️
@here/harp-mapview/lib/MapView.ts 72.83% <100.00%> (+0.39%) ⬆️
@here/harp-mapview/lib/text/TextCanvasFactory.ts 100.00% <100.00%> (ø)
@here/harp-mapview/lib/MapViewThemeManager.ts 81.18% <0.00%> (+1.98%) ⬆️
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1ee9ff7...ea961cd. Read the comment docs.

Copy link
Collaborator

@atomicsulfate atomicsulfate left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so far I found something important, I'll continue the review after that is addressed.

@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 1, 2020

@harpgl-bot retest this please

@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 1, 2020

@harpgl-bot retest this please

Copy link
Collaborator

@atomicsulfate atomicsulfate left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FInished review, just some minor comments.

@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 3, 2020

macbook tests please

1 similar comment
@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 3, 2020

macbook tests please

@atomicsulfate atomicsulfate self-requested a review December 3, 2020 08:23
Copy link
Collaborator

@atomicsulfate atomicsulfate left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

@atomicsulfate atomicsulfate self-requested a review December 3, 2020 08:24
atomicsulfate
atomicsulfate previously approved these changes Dec 3, 2020
Frauke Fritz added 13 commits December 3, 2020 11:28
* Makes PoiRenderer independent from TextCanvas
* PoiRenderer renders on its own
* Icons can be rendered even if no FontCatalog is availble

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
* PoiRenderer supports callback between layers
* TextCanvas supports rendering of layers inside a scope

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
…d TextCanvas

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
…ache

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
 * PoiRenderer passes PoiLayer to PoiBuffer instead of the whole instance
 * Removes MapView Dependency, and passes only needed information instead

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Change-Id: I16eea8ce448f8f172351afd4f1fbd3efb3162b9b
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
…furter cleanup in PoiRenderer

 * PoiRenderer only creates new layer on actual Buffer generation
 * PoiInfos with already created buffers from a former PoiRenderer are handled
 * MapView contains one PoiRenderer which is reset instead of recreated on theme change
 * Fixes issue introduced to TextStyleCache not being able to access config name of FontCatalog

Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
…furter cleanup in PoiRenderer

 * PoiRenderer only creates new layer on actual Buffer generation
 * PoiInfos with already created buffers from a former PoiRenderer are handled
 * MapView contains one PoiRenderer which is reset instead of recreated on theme change
 * Fixes issue introduced to TextStyleCache not being able to access config name of FontCatalog

Change-Id: Ie4b961b37904d10940d76ec2ae62e3eb282bcb58
Signed-off-by: Frauke Fritz <frauke.fritz@here.com>
@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 3, 2020

macbook tests please

@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 3, 2020

@harpgl-bot retest this please

@FraukeF
Copy link
Contributor Author

FraukeF commented Dec 3, 2020

macbook tests please

@atomicsulfate atomicsulfate self-requested a review December 3, 2020 11:53
@FraukeF FraukeF merged commit 7624c25 into master Dec 3, 2020
@FraukeF FraukeF deleted the poi-renderer branch December 3, 2020 14:22
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants