robo-cjk icon indicating copy to clipboard operation
robo-cjk copied to clipboard

Rename DC or AE glyph should propagate to all parent glyphs

Open justvanrossum opened this issue 3 years ago • 2 comments

As discussed during the meeting today, this isn't easy.

In my view, this is what should happen, when a DC or AE gets renamed:

  1. Check which parent glyphs use the DC/AE being renamed
  2. Lock all involved glyphs. If locking fails: bail out, don't rename (report who owns the locks)
  3. Check that the set calculated in step 1 is still the same. If no: unlock and bail out
  4. Rename the DC/AE, and fix the references in all the parent glyphs
  5. Unlock all

Should this be done at the RoboCJK client level, or is it a task that can be delegated to the server? The latter would be much better for performance.

My assuption: renaming DCs or AEs should be rare, therefore it's an acceptable tradeoff that the procedure to do it is a little slow or cumbersome.

Cc @fabiocaccamo @GaetanBaehr @JeremieHornus @jbmorizot

Also relates to #23: renaming should be impossible to do accidentally, and should require an obnoxious comfirmation dialog.

justvanrossum avatar Apr 27 '21 09:04 justvanrossum