Improved text rendering performance

This commit is contained in:
alonso.torres 2023-01-04 16:12:00 +01:00
parent 837b52aea1
commit 84e9f69213
7 changed files with 148 additions and 85 deletions

View file

@ -63,7 +63,8 @@
[shape-id]
(when (some? shape-id)
(let [text-nodes (dom/query-all (dm/str "#html-text-node-" shape-id " .text-node"))
(let [text-nodes (-> (dom/query (dm/fmt "#html-text-node-%" shape-id))
(dom/query-all ".text-node"))
load-fonts (->> text-nodes (map resolve-font))
process-text-node