Welcome to TalkGraphics.com
Page 1 of 2 12 LastLast
Results 1 to 10 of 13
  1. #1
    Join Date
    Mar 2010
    Location
    Cork. Ireland
    Posts
    54

    Default SVG files not centred when saving?

    Hi Guys....male and female!

    I was using sparkol videoscribe and Xara to make the svg files to import them to videoscribe.

    When I export them it asks for 3 different formats and dpi.

    I find that when I import the file into videoscribe the svg image is always at the bottom half of the box handles.

    It does not crop and save the image as such.

    Is there something I am missing?

    I have used Xara for many years and do not usually come across a problem. I probably am missing something?

    Your help would be much appreciated.

    Thanks.

  2. #2
    Join Date
    Feb 2007
    Location
    UK
    Posts
    21,326

    Default Re: SVG files not centred when saving?

    there was a thread on videoscribe last year [not sure if it helps]

    http://www.talkgraphics.com/showthre...ng-Videoscribe

  3. #3

    Default Re: SVG files not centred when saving?

    Quote Originally Posted by GanAnim View Post
    Hi Guys....male and female!

    I was using sparkol videoscribe and Xara to make the svg files to import them to videoscribe.

    When I export them it asks for 3 different formats and dpi.

    I find that when I import the file into videoscribe the svg image is always at the bottom half of the box handles.

    It does not crop and save the image as such.

    Is there something I am missing?

    I have used Xara for many years and do not usually come across a problem. I probably am missing something?

    Your help would be much appreciated.

    Thanks.
    Copy your art into the Blank Photo template. Export from it. The bounding box will be correct.

    Mike

  4. #4
    Join Date
    Feb 2007
    Location
    UK
    Posts
    21,326

    Default Re: SVG files not centred when saving?

    as far as I can see Mike's suggestion does not work for SVG imported into videoscribe, it did not fix the offset when i tried it - there is always Egg's suggestion in the other thread, which is rather a pain

    importing the SVG into inkscape and saving does not seem to fix the problem, [although SVGs created in inkscape are fine] - but on the other hand importing xara SVG into illustrator and saving out did fix it, but you may not have illustrator

    I'm inclined to think it an issue with the SVG internal formatting... which is a variable standard..

    can't say I did exhaustive testing, maybe someone cleverer/lucky will find a solution

  5. #5

    Default Re: SVG files not centred when saving?

    Not having videoscribe, I just put them into a browser.

    Any SVG from XDP that used a non-Photo Template page, whether the graphic was selected or not, had a large bounding box. Using the Photo Template, the graphics were always nestled up to the 0,0 (top, top left) of the browser. Just inserting it into HTML without any positioning or sizing code, also put it to the 0,0 coordinates.

    If I run a compare on the two files (they are just text files after all), there are 3 lines that use coordinates and they are different. But likely it is these two lines that matter...only the parts of the two lines that differ:

    From the 0,0 file:
    <... width="354.417pt" height="356.491pt" viewBox="0 0 354.417 356.491">

    From the offset file:
    <... width="612pt" height="792pt" viewBox="0 0 612 792">

    While both have the view box set to 0,0, start coordinates, the size of the viewBox is what matters. In the first instance, it is the precise size of the star shape I exported. In the second instance, the export corresponds to the page size one is using.

    Because XDP is exporting correctly--I have used SVG for web pages out of XDP--it may just be that the SVG is being interpreted incorrectly on the receiving end. Web browsers interpret it correctly.

    OK. Just got back from reading the other thread. The Defs tag should not affect the application in question. But evidently it does. VideoScribe, if they cannot handle the <Def></Def> section should ignore it.

  6. #6
    Join Date
    Feb 2007
    Location
    UK
    Posts
    21,326

    Default Re: SVG files not centred when saving?

    aye well, we do have videoscribe as it happens [not that I make any real use of it myself]...

    but to confirm for myself at least, I created an SVG star in xara designer - file named star.svg

    then using notepad I deleted all the content starting with <defs> and ending with </defs> and saved the edited file as star1.svg

    the star1.svg imports into videoscribe correctly....
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	sshotsvgimportvs.png 
Views:	80 
Size:	4.4 KB 
ID:	100691  
    Attached Files Attached Files

  7. #7

    Default Re: SVG files not centred when saving?

    Yep, believed Egg when he wrote that was the issue. Perhaps someone should file a bug report with VideoScribe. It is a valid section in the SVG spec. It's used for defining the initial properties so the original can be altered and resused elsewhere (same page, different page) and be altered.

    Or, file a enhancement request with Xara to have the option of not including the <def></def> section. But I don't know if that section affects any other application except VideoScribe. I haven't run into a problem with its inclusion in anything but these two reports, both concerning VS.

  8. #8
    Join Date
    Feb 2007
    Location
    UK
    Posts
    21,326

    Default Re: SVG files not centred when saving?

    sure, Egg is not a man to get that sort of thing wrong..

    but.. defs is info for the XML parser.. so what exactly is the issue is therefore unclear to me.. can't say it's the inclusion of defs tag in itself necessarily...

  9. #9

    Default Re: SVG files not centred when saving?

    Seeing how you use VS, you could just try deleting the contents between the tag but leaving an empty <def></def> section.

    Then again, if I wanted to use XDP with VS, I would just delete that section. And If I need multiple files, I would have my text editor run through a folder of SVG files and remove the section in all SVG files it finds. It would take seconds. Seems the easiest solution unless there were just a few files which could be handled in notepad...

    Interesting stuff, though.

  10. #10
    Join Date
    Feb 2007
    Location
    UK
    Posts
    21,326

    Default Re: SVG files not centred when saving?

    empty <defs></defs> appears to works fine....

 

 

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •