Coder Social home page Coder Social logo

Announce: SVG Editor about oksvg HOT 2 OPEN

srwiley avatar srwiley commented on July 18, 2024
Announce: SVG Editor

from oksvg.

Comments (2)

srwiley avatar srwiley commented on July 18, 2024

That looks great Stuart. Also I like you previous suggestion also. I just have been focused on different things for a while.
If you would like to submit a pull request to make the line width proportional to the image scale, as per the specifications, I will take a good look. Otherwise I assure you I will get to it eventually.

Also, if you have the time please take a look at the imageElt branch in oksvg submitted by another github user. I want to clean it up somewhat, like take out the logging in the inner loops, but overall what do you think about things like the modules statement?

from oksvg.

stuartmscott avatar stuartmscott commented on July 18, 2024

Thanks Steven!

I think the change would be two parts, one in the data structure to parse and hold the value (either fixed, or percentage), and another in the rasterizer to either pass through the fixed value or calculate the percentage based on the requested output size.

The imageElt branch looks okay, moving to the Shape interface should give more flexibility to support future features.

I found the comments lacking and don't provide any more information than the line of code they annotate: // Shape type., // Image type., // KernelUsed var., and // DrawTransformed func.

I made the switch to Go modules a while back and for the most part I'm glad I did, however there is one scenario where they could be better - they slow down local experimentation across projects. Consider the case where you want to try out a change across rasterx and oksvg, if your current setup has them both in the GOPATH then you can make the changes and the compiler would find them. However with go modules, every dependency is versioned so you have two options either make a change in rasterx, commit and push, then switch to oksvg and run go get to pull down the latest version of rasterx. If you're experimenting you may not want to push a half-baked change. You're other option is to use an replace statement in oksvg to say replace github.com/srwiley/rasterx => ../rasterx to tell go to use the local copy, but you do not want to add this replace directive to the repository as it could break other developers setups, so you need to remember not to add it to any resulting commits. Ideally there would be a go.mod.local or some other name that you can add to .gitignore where you can put these replace directives for local development unfortunately there has not been much progress: golang/go#26640

from oksvg.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.