Working on a KanjiVG files editor

56 views
Skip to first unread message

pascal Baillehache

unread,
Jul 2, 2025, 9:21:20 AMJul 2
to KanjiVG
Hi everyone,

Each time someone requests for the correction of a kanji and that can't be (easily) done I think I should take some time to build a dedicated tool. Of course, I never have time and always forget about it, but this week the timing was finally right (not that I'm particularly empty handed at the moment, more because the mood was right). Then, I've made a prototype of a KanjiVG files editor and it's working enough to introduce it I think.

It's one simple html file, nothing to install, just open it in a browser (a local copy or one available online), works offline too, no ads/cookies/etc. Currently the functionalities are limited, although already enough to address some of the common requests I believe. I only wanted to quickly have something to show. However from there it wouldn't be difficult for me to add much more, eventually to make it a complete editor able to edit existing kanji or create new ones from scratch.

I'm not releasing it yet, only sharing here a demo video, and requesting for your comments. If the response is positive I'll keep working on it. If not, that's fine, I have plenty of other projects to have fun with. Be frank! :-)

Waiting for your comments,
Pascal

Ben Bullock

unread,
Jul 2, 2025, 6:04:07 PMJul 2
to kan...@googlegroups.com
On Wed, 2 Jul 2025 at 22:21, pascal Baillehache <baillehac...@gmail.com> wrote:

I'm not releasing it yet, only sharing here a demo video, and requesting for your comments. If the response is positive I'll keep working on it. If not, that's fine, I have plenty of other projects to have fun with. Be frank! :-)
 
This looks like the sort of thing we need to edit the characters in a browser. 

Chase Colburn

unread,
Jul 3, 2025, 6:45:53 AMJul 3
to KanjiVG
This looks really good. I was also thinking of creating an editor. There are about 600 kanji in my project that don't have stroke data available that I plan to work on. What you have created so far looks very useful. Good job!

-Chase

pascal Baillehache

unread,
Jul 3, 2025, 8:21:20 AMJul 3
to KanjiVG

> This looks like the sort of thing we need to edit the characters in a browser. 
Thank you Ben.

> This looks really good. I was also thinking of creating an editor. There are about 600 kanji in my project that don't have stroke data available that I plan to work on. What you have created so far looks very useful. Good job!
Thank you Chase. That's motivating ! I'll keep working on it a few more days and get back to you here.


pascal Baillehache

unread,
Jul 7, 2025, 2:07:10 AMJul 7
to KanjiVG
Hi everyone,
KanjiVGEditor beta.000 is complete. There is a new video to introduce it here:
and an article about it on my website here:
It can be used directly online here:
or by copying the html file locally and opening it in your browser.
I'm eager to hear your comments!
Pascal

Ben Bullock

unread,
Jul 7, 2025, 4:24:35 AMJul 7
to kan...@googlegroups.com
On Mon, 7 Jul 2025 at 15:07, pascal Baillehache <baillehac...@gmail.com> wrote:
Hi everyone,
KanjiVGEditor beta.000 is complete. There is a new video to introduce it here:
and an article about it on my website here:
It can be used directly online here:
or by copying the html file locally and opening it in your browser.
I'm eager to hear your comments!
Pascal

Thanks for uploading. It seems to have a lot of useful features.


Chase Colburn

unread,
Jul 7, 2025, 9:41:42 AMJul 7
to kan...@googlegroups.com
Brilliant job Pascal. You just made my work infinitely easier. I really appreciate you taking the time to put this together. Hopefully it can be linked to from the KanjiVG github so others can find it easily. 

-Chase

--
--
You received this message because you are subscribed to the "KanjiVG" group.
For options and unsubscribing, visit this group at
http://groups.google.com/group/kanjivg
---
You received this message because you are subscribed to a topic in the Google Groups "KanjiVG" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/kanjivg/oUsLDSQNPrQ/unsubscribe.
To unsubscribe from this group and all its topics, send an email to kanjivg+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/kanjivg/2e98b470-3cb9-414f-85ab-743cef90678en%40googlegroups.com.

Ben Bullock

unread,
Jul 7, 2025, 8:35:01 PMJul 7
to kan...@googlegroups.com
On Mon, 7 Jul 2025 at 15:07, pascal Baillehache <baillehac...@gmail.com> wrote:
Hi everyone,
KanjiVGEditor beta.000 is complete. There is a new video to introduce it here:
and an article about it on my website here:
It can be used directly online here:


I haven't tried all the features yet but here are some things I noticed:

The <title> is outside the <head> area so it fails to validate, see https://validator.w3.org/

It aligns as vertical blocks even when the browser is wide enough to accommodate the blocks horizontally. I was able to fix this by changing width 90% in divMain CSS to 100%.

At the moment there don't seem to be that many ways to manipulate the numbers except by editing text fields. As you might know a long term problem of kanjiVG has been that some of the stroke numbers are positioned badly or are missing so a big feature which would help with that would be a way to drag and drop stroke numbers.

Anyway it looks very good so far in terms of being able to edit the shapes much more easily than we were before. I haven't tried saving the file yet.

pascal Baillehache

unread,
Jul 7, 2025, 9:13:36 PMJul 7
to KanjiVG
> Brilliant job Pascal. You just made my work infinitely easier. I really appreciate you taking the time to put this together. Hopefully it can be linked to from the KanjiVG github so others can find it easily. 

Thanks Chase. I'm glad to hear that.

> I haven't tried all the features yet but here are some things I noticed:
> The <title> is outside the <head> area so it fails to validate, see https://validator.w3.org/
> It aligns as vertical blocks even when the browser is wide enough to accommodate the blocks horizontally. I was able to fix this by changing width 90% in divMain CSS to 100%.
> At the moment there don't seem to be that many ways to manipulate the numbers except by editing text fields. As you might know a long term problem of kanjiVG has been that some of the stroke numbers are positioned badly or are missing so a big feature which would help with that would be a way to drag and drop stroke numbers.
> Anyway it looks very good so far in terms of being able to edit the shapes much more easily than we were before. I haven't tried saving the file yet.

Thank you very much for the feedback, Ben. 
I have corrected the <title> tag problem and checked that it now passes the validation.
I have modified the CSS to make better use of the available width.
You can edit the position of the text label with the 'translate' tool. First select the label you wish to translate, then select 'transform'>'translate', then translate the label by dragging your mouse in the graphical area. Also check the demo video from 07:40 for an example.

pascal Baillehache

unread,
Jul 7, 2025, 9:18:25 PMJul 7
to KanjiVG
Clarifying something about the text selection: it can't be selected directly in the graphical area, you have to click on the element in the structured data area.

Ben Bullock

unread,
Jul 9, 2025, 2:57:09 AMJul 9
to kan...@googlegroups.com
On Tue, 8 Jul 2025 at 10:13, pascal Baillehache <baillehac...@gmail.com> wrote:

You can edit the position of the text label with the 'translate' tool. First select the label you wish to translate, then select 'transform'>'translate', then translate the label by dragging your mouse in the graphical area. Also check the demo video from 07:40 for an example.


Thanks for the guidance on how to do that with the mouse. Moving/adding numbers to the characters has been one of the more annoying problems and this looks like it will be a big help. 

pascal Baillehache

unread,
Jul 9, 2025, 6:34:28 AMJul 9
to KanjiVG
Great ! If you have ideas of other functionalities that would be good to add feel free to ask. I'm willing to keep working on it little by little, but for now I'm just waiting to see if you and Chase find bugs in the beta version. Once everything seems fine I'll tag it as v1.0 and then I'll see how to improve that tool.

pascal Baillehache

unread,
Sep 3, 2025, 11:09:10 PM (9 days ago) Sep 3
to KanjiVG
Hi everyone,
I had some time available to work on KanjiVGEditor this week. 
Without further comments from you I assumed the app in its current state was good enough to tag as an initial version. So I went through the whole code, made a lot of cleaning, found and corrected a few bugs, and tagged it as version.01.000.000. I haven't added any new features, but now I have a clean state to keep working on.
It's also now available as a Git repository on CodeBerg: 
The ready-to-use online version is still available and up to date:
Cheers,
Pascal

Ben Bullock

unread,
Sep 4, 2025, 5:22:18 AM (9 days ago) Sep 4
to kan...@googlegroups.com
Thank you for your work Pascal.

--
--
You received this message because you are subscribed to the "KanjiVG" group.
For options and unsubscribing, visit this group at
http://groups.google.com/group/kanjivg
---
You received this message because you are subscribed to the Google Groups "KanjiVG" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kanjivg+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/kanjivg/024d49ab-98b9-4b20-8917-92da271ac21en%40googlegroups.com.

pascal Baillehache

unread,
Sep 5, 2025, 11:00:33 PM (7 days ago) Sep 5
to KanjiVG
Hi Ben,
Looking for which features to add next to KanjiVGEditor I came back to your previous messages. As you mentioned the position of stroke numbers as a long term problem I'm thinking of what could be done to help with that. 
Here are some ideas:
1) Add the possibility to select numbers in the drawing area (currently possible only in the structure area) would make it easier to use.
2) Automatically add missing numbers and remove duplicates. When adding, simply positioning the number next to the start of its stroke and let the user refine the position manually.
3) Automatically position the numbers. That would require to define what is a "good" position. Is that simply "as near as possible to the beginning of the stroke without overlapping strokes and numbers" ?
1) and 2) are easy, so I think I'll go ahead and do it. 3) is doable but requires much more work, and I would need your help to define what is a "good" position. Do you think it's worth it ?

Ben Bullock

unread,
Sep 5, 2025, 11:54:33 PM (7 days ago) Sep 5
to kan...@googlegroups.com
These all sound like good ideas, although the automatic positioning of numbers might take a lot of work. The main thing which I think would make this useful is the ability to get and put the edited images from a Github repository. That way people can use it to edit their own repository of KanjiVG.


pascal Baillehache

unread,
Sep 6, 2025, 10:28:54 PM (6 days ago) Sep 6
to KanjiVG
I'm not sure to understand. Do you mean, you'd like to be able to pull/commit/push from/to a remote GitHub repository directly from the app ?

Ben Bullock

unread,
Sep 7, 2025, 11:47:14 PM (5 days ago) Sep 7
to kan...@googlegroups.com
On Sun, 7 Sept 2025 at 11:28, pascal Baillehache <baillehac...@gmail.com> wrote:
I'm not sure to understand. Do you mean, you'd like to be able to pull/commit/push from/to a remote GitHub repository directly from the app ?

It would be nice to be able to at least load the image from a URL rather than a file on the local computer.
 

pascal Baillehache

unread,
Sep 9, 2025, 10:38:59 PM (3 days ago) Sep 9
to KanjiVG
Actually I thought of doing that from the beginning but then I thought, "and once the user has edited the kanji, what ? (s)he needs to save it on disk anyway". I couldn't see the workflow and then I did load/save from/to disk only.
I can do it, however it raises new questions. How to specify the URL ? Direct input of something like "https://raw.githubusercontent.com/KanjiVG/kanjivg/refs/heads/master/kanji/00021.svg" isn't very user friendly, right ? To hide the URL and to choose only the kanji looks better. Then, what if the user wants to load from a forked repository, or another branch ? So, when loading from URL, ask for the user/repository/branch/kanji (with defaults set to KanjiVG main) ? Is that how you see it ? If it is, I'll add it.
Coming back to the commit/push functionalities. I read a bit about it because I had never done it as a feature of a web app. I think I can do it, however my big concern is that it then requires user credentials and dealing with the GitHub API. Nothing impossible, but the scope of the web app suddenly inflates a good deal. Given the small amount of time I can dedicate to this project I'm not really eager to go that far. My initial goal was to make a simple SVG editor tailored for KanjiVG files. I'd prefer version control tasks to be handled by the user externally as (s)he does usually.

Ben Bullock

unread,
Sep 10, 2025, 2:35:47 AM (3 days ago) Sep 10
to kan...@googlegroups.com
Hi Pascal

It's OK if you don't have any more time to add the features so please don't worry about that. I personally actually do not even have a copy of the files on the computer which I'm using to type this so I would have to load and save to a URL. Someone requested an addition of characters so now your editor exists we can direct him there.

Thanks again for your work so far.

Reply all
Reply to author
Forward
0 new messages