Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: "null" instead of "@null" ? #36

Closed
AndroidDeveloperLB opened this issue Feb 29, 2016 · 9 comments
Closed

Bug: "null" instead of "@null" ? #36

AndroidDeveloperLB opened this issue Feb 29, 2016 · 9 comments

Comments

@AndroidDeveloperLB
Copy link

using this SVG as an input:

<svg width="476" height="476" xmlns="http://www.w3.org/2000/svg">
 <!-- Created with SVG-edit - http://svg-edit.googlecode.com/ -->
 <g>
  <title>Layer 1</title>
  <ellipse ry="198.5" rx="198.5" id="svg_3" cy="238" cx="238" stroke-linecap="null" stroke-linejoin="null" stroke-width="0" stroke="#000000" fill="#f3f3f3"/>
 </g>
</svg>

will create this:

<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
    android:width="476dp"
    android:height="476dp"
    android:viewportWidth="476"
    android:viewportHeight="476">

    <path
        android:fillColor="#f3f3f3"
        android:strokeColor="#000000"
        android:strokeLineJoin="null"
        android:strokeLineCap="null"
        android:pathData="M 238 39.5 C 347.628522841 39.5 436.5 128.371477159 436.5 238 C 436.5 347.628522841 347.628522841 436.5 238 436.5 C 128.371477159 436.5 39.5 347.628522841 39.5 238 C 39.5 128.371477159 128.371477159 39.5 238 39.5 Z" />
</vector>

but Android studio can't handle the nulls.

@AndroidDeveloperLB
Copy link
Author

Anyway, I think that if the stroke width is 0, all stroke-related stuff should be removed, because it doesn't need to get drawn.

@yuraj11
Copy link
Collaborator

yuraj11 commented Mar 1, 2016

That's not an ordinary svg - also not sure If valid one with null values.

@AndroidDeveloperLB
Copy link
Author

Well, I'm not an expert in SVG, but the web browser showed it fine, and it was created via an online SVG editor :
http://svg-edit.googlecode.com/svn-history/r1771/trunk/editor/svg-editor.html

yuraj11 added a commit that referenced this issue Mar 24, 2016
yuraj11 added a commit that referenced this issue Mar 24, 2016
@yuraj11
Copy link
Collaborator

yuraj11 commented Mar 24, 2016

Fixed

@yuraj11 yuraj11 closed this as completed Mar 24, 2016
@AndroidDeveloperLB
Copy link
Author

Thank you.
Say, do you know perhaps if Google is working on such a conversion tool?

@yuraj11
Copy link
Collaborator

yuraj11 commented Mar 24, 2016

There is Vector Asset Studio in Android Studio but It is not good as this tool. Maybe in future.

@AndroidDeveloperLB
Copy link
Author

Isn't it a tool that only takes vectors, and create images out of them?

On Thu, Mar 24, 2016 at 2:09 PM, Juraj Novák notifications@github.com
wrote:

There is Vector Asset Studio in Android Studio but It is not good as this
tool. Maybe in future.


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
#36 (comment)

@yuraj11
Copy link
Collaborator

yuraj11 commented Mar 24, 2016

No It generates VectorDrawable xml.

@AndroidDeveloperLB
Copy link
Author

It does?!
From SVG ?
How do you use it?
And what's not good in it?
Odd that I never heard about it.

On Thu, Mar 24, 2016 at 2:20 PM, Juraj Novák notifications@github.com
wrote:

No It generates VectorDrawable xml.


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
#36 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants