i am able to get the <g> element for any JComponent using: SwingSVGPrettyPrint.print(myJComponent, mysvgGenerator);
once i have the <g> element, i can then call mysvgGenerator.translate( thisManyX, thisManyY ); to successfully reposition my <g> element where i want it. i do this iteratively, to all of a parent component's children, each with its own <g> element. then i add these all to another, final document. the problem: the width and height of different JComponents are applied to other JComponents! what is happening: digging into the generated .svg document, i found that there are repeated clipPath elements. for example: under one <g>: <g id="javax.swing.JTextArea1"> <defs id="defs4"> <clipPath clipPathUnits="userSpaceOnUse" id="clipPath6"> <path d="M0 0 L0 116 L139 116 L139 0 Z" /> </clipPath> </defs> and under another <g> in the same final document: <g id="javax.swing.JToggleButton2"> <defs id="defs3"> <clipPath clipPathUnits="userSpaceOnUse" id="clipPath6"> <path d="M0 0 L0 18 L296 18 L296 0 Z" /> </clipPath> </defs> anyone know of a solution? is there a way to tell <g>'s generated from other documents to not repeat already used clipPath id #s? thanks ERIK! --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
