I am writing a program which extracts the ink data from OneNote pages and puts them into a single ink object. However, I'm running into a problem figuring out the positioning of each piece of ink relative to the entire page. If the schema looks something like this:
<one:Outline > <one:Position x="161.0078582763672" y="75.74172973632812" z="1" /> <one:Size width="332.192138671875" height="56.32440567016602" /> <one:Indents> <one:Indent level="2" indent="45.6378059387207" /> </one:Indents> <one:OEChildren> <one:OE> <one:InkWord recognizedText="Bulleted" x="0.0" y="0.0" inkOriginX="-161.0078582763672" inkOriginY="-75.74172973632812" width="165.1181182861328" height="56.32441329956055"> <one:Data>[64BitString]</one:Data> </one:InkWord> <one:InkWord width="24.74646377563477" height="57.00472259521484"> <one:Space /> </one:InkWord> <one:InkWord recognizedText="List" x="190.346435546875" y="0.0" inkOriginX="-190.346435546875" inkOriginY="2.125983238220215" width="93.85513305664062" height="56.32440567016602"> <one:Data>[64BitString]</one:Data> </one:InkWord> </one:OE> </one:OEChildren> </one:Outline>
What combination of the Position x attribute (posX) and the InkWord x and inkOriginX attributes should I use to get the correct offset for the embedded strokes? I tried using posX + x + inkOriginX, and that worked for one of my pages, but not for others. Is there a simple formula that works for everything?
Thanks!
Amber
|
|