Review Request: load and save draw:id and text:id also as xml:id

Boudewijn Rempt boud at valdyas.org
Wed Feb 29 08:15:06 GMT 2012


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/104074/
-----------------------------------------------------------

(Updated Feb. 29, 2012, 8:15 a.m.)


Review request for Calligra.


Changes
-------

Final version, I think -- animations now work as well.


Description
-------

draw:id and text:id are deprecated and to be replaced by xml:id. This patch creates a new class KoElementReference that encapsulates loading and saving all three tags, as well as automatically generating a unique id. This is used to make sure that if two items want to save an xml:id on the same element, we only have one, unique tag saved.

I'm not completely happy yet, since parts of KoShapeSavingContext still create numbered, prefixed id's with hidden meanings that are not clearly connect to what the idref actually links to for the master pages. Imo, xml:id should always be guaranteed unique and there should be a clear code-path between the entity that is linked to from an element and the element itself.


This addresses bug 288644.
    http://bugs.kde.org/show_bug.cgi?id=288644


Diffs (updated)
-----

  filters/stage/kpr2odf/Filterkpr2odf.cpp df7079b 
  filters/stage/pptx/PptxXmlSlideReader.cpp eaee384 
  filters/words/docx/DocxXmlDocumentReader.cpp 6aa31f5 
  filters/words/oowriter/ExportFilter.h dea56bd 
  filters/words/oowriter/ExportFilter.cc ff44e0c 
  karbon/common/KarbonDocument.cpp 6057a18 
  krita/ui/flake/kis_shape_layer.cc 8aaca9d 
  krita/ui/flake/kis_shape_selection.cpp 95ebeb6 
  krita/ui/kis_paintop_box.cc 5434e8a 
  krita/ui/ko_favorite_resource_manager.h d3605b8 
  krita/ui/ko_favorite_resource_manager.cpp d6c0c10 
  libs/flake/KoConnectionShape.cpp fda3463 
  libs/flake/KoImageCollection.cpp 27b8260 
  libs/flake/KoShape.cpp be34b8a 
  libs/flake/KoShapeLoadingContext.h 87b0830 
  libs/flake/KoShapeLoadingContext.cpp 0573ddf 
  libs/flake/KoShapeSavingContext.h c73a680 
  libs/flake/KoShapeSavingContext.cpp 46cb477 
  libs/kopageapp/KoPADocument.cpp 49ac34a 
  libs/kopageapp/KoPAPage.cpp fbcf49d 
  libs/kopageapp/KoPAPastePage.cpp 9fd795e 
  libs/kopageapp/tests/TestPACopyPastePage.h 363f803 
  libs/kopageapp/tests/TestPACopyPastePage.cpp 3b023b8 
  libs/kotext/KoDocumentRdfBase.h d6f467a 
  libs/kotext/KoDocumentRdfBase.cpp 7b6b38c 
  libs/kotext/KoInlineNote.h 91823e9 
  libs/kotext/KoInlineNote.cpp 897214c 
  libs/kotext/KoInlineObject.h 8a1d627 
  libs/kotext/KoTextAnchor.cpp 414b347 
  libs/kotext/KoTextBlockData.h cc1528b 
  libs/kotext/KoTextBlockData.cpp 116b432 
  libs/kotext/KoTextDrag.cpp 381f4de 
  libs/kotext/KoTextInlineRdf.h fd7bb5e 
  libs/kotext/KoTextInlineRdf.cpp f449426 
  libs/kotext/changetracker/KoChangeTracker.h 33c2696 
  libs/kotext/changetracker/KoChangeTracker.cpp 51b9c5e 
  libs/kotext/opendocument/KoTextLoader.cpp a15b08e 
  libs/kotext/opendocument/KoTextWriter.h fd0689c 
  libs/kotext/opendocument/KoTextWriter.cpp 56125d3 
  libs/kotext/opendocument/KoTextWriter_p.h c89e895 
  libs/kotext/opendocument/KoTextWriter_p.cpp 1dbc8bb 
  libs/kotext/opendocument/tests/CMakeLists.txt c386cfb 
  libs/kotext/opendocument/tests/TestChangeTracking.cpp 665636b 
  libs/main/rdf/KoDocumentRdf.h fabc628 
  libs/main/rdf/KoDocumentRdf.cpp bfaa9ec 
  libs/odf/CMakeLists.txt 838d4f6 
  libs/odf/KoElementReference.h PRE-CREATION 
  libs/odf/KoElementReference.cpp PRE-CREATION 
  libs/odf/KoEmbeddedDocumentSaver.cpp 36506ca 
  libs/odf/KoGenChange.cpp 2cd2d97 
  libs/odf/KoGenChanges.h d7b51ee 
  libs/odf/KoGenChanges.cpp b64d32d 
  libs/odf/tests/CMakeLists.txt ee86038 
  libs/odf/tests/TestKoElementReference.h PRE-CREATION 
  libs/odf/tests/TestKoElementReference.cpp PRE-CREATION 
  plan/kptview.h 5743e03 
  plan/kptview.cpp 03ef17e 
  plan/libs/kernel/kptappointment.h 50bb17e 
  plan/libs/kernel/kptappointment.cpp e5343f0 
  plan/libs/kernel/kptcalendar.h d2c133a 
  plan/libs/kernel/kptcalendar.cpp 3db2b87 
  plan/libs/kernel/kptnode.h 671458b 
  plan/libs/kernel/kptnode.cpp b030f51 
  plan/libs/kernel/kptproject.h e7c3eac 
  plan/libs/kernel/kptproject.cpp b74821d 
  plan/libs/kernel/kptresource.h 56661cc5 
  plan/libs/kernel/kptresource.cpp d5bd68e 
  plan/libs/kernel/kptschedule.h 3bc3a22 
  plan/libs/kernel/kptschedule.cpp 7b147c9 
  plan/libs/kernel/kptschedulerplugin.cpp 2a663e7 
  plan/libs/kernel/kpttask.h 60cfb8f 
  plan/libs/kernel/kpttask.cpp 18e9f50 
  plan/libs/models/kptresourceappointmentsmodel.cpp 58b0d01 
  plan/libs/ui/kptscheduleeditor.cpp 555e968 
  plan/libs/ui/kpttaskstatusview.cpp 011d02f 
  plan/libs/ui/locale/localemon.cpp 0124151 
  plan/libs/ui/reports/odt/KoSimpleOdtCheckBox.cpp 49a82bb 
  plan/libs/ui/reports/odt/KoSimpleOdtLine.cpp c8a4b9c 
  plan/libs/ui/reports/odt/KoSimpleOdtPicture.cpp cd3216c 
  plan/libs/ui/reports/odt/KoSimpleOdtTextBox.cpp 717b867 
  plan/libs/ui/reports/reportscripts.cpp 69ac323 
  plan/libs/ui/reports/reportview.cpp eed86fe 
  plan/plugins/schedulers/rcps/KPlatoRCPSPlugin.cpp 3b5153f 
  plan/plugins/schedulers/rcps/KPlatoRCPSScheduler.cpp e743386 
  plan/plugins/schedulers/tj/PlanTJPlugin.cpp 827bc31 
  plan/plugins/schedulers/tj/PlanTJScheduler.cpp 084a2fe 
  plan/plugins/scripting/Project.cpp b9d9ce0 
  plugins/pathshapes/enhancedpath/EnhancedPathShape.cpp 57aa6fd 
  stage/part/animations/KPrAnimationBase.cpp b544485 
  stage/part/animations/KPrAnimationLoader.cpp 45467dd 
  stage/part/animations/KPrShapeAnimation.cpp c7fff3f 
  tables/part/Doc.cpp 25e3fd3 
  words/part/KWOdfLoader.cpp 5c568df 
  words/part/KWOdfWriter.cpp b998485 

Diff: http://git.reviewboard.kde.org/r/104074/diff/


Testing
-------

Manual testing and unittests; on Tuesday I will do a practical test at SKF.


Thanks,

Boudewijn Rempt

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/calligra-devel/attachments/20120229/9817096a/attachment.htm>


More information about the calligra-devel mailing list