Coder Social home page Coder Social logo

jscapturecanvas's People

Watchers

 avatar  avatar

jscapturecanvas's Issues

sprintf not available without php.js

What steps will reproduce the problem?
1. latest code release with gradiented svg
2.
3.

What is the expected output? What do you see instead?
expected to see gradiented shape on canvas,
instead see nothing as script fatally errors

What version of the product are you using? On what operating system?
latest, OSX on FF20 and Chrome26

Please provide any additional information below.
Can be fixed by changing functions jsContext2d.prototype.createLinearGradient 
and jsContext2d.prototype.createRadialGradient

from 
state.output += sprintf ('this.gradients [%d].addColorStop (%f, "%s");\n',
                 n, stop, color);

to
state.output += 'this.gradients ['+n+'].addColorStop ('+stop+', 
"'+color+'");\n';

Original issue reported on code.google.com by [email protected] on 9 May 2013 at 11:03

Errors while trying to load SVG file - quandraticCurveTo function doesn't exist on the 2d context

What steps will reproduce the problem?
1. load attached file in your tester (http://mtcc.com/site/jscanvastest.html)
2. I've used exactly that code on my local machine and in Chrome I get an 
exception, 'Uncaught TypeError: Cannot call method 'apply' of undefined' 
jscanvas.js line 277 - it tries to call 'quandraticCurveTo' function on the 
this.canvas.real2dContext and apparetly it doesn't exist!

What is the expected output? What do you see instead?
Should proceed with the file - I can draw the button correctly by using canvg 
alone.

What version of the product are you using? On what operating system?
canvg 1.3 and jscanvas 1.0.5.

Please provide any additional information below.
When instead of my file I try to load yours (phzavatar.svg) I get the following 
error:
Uncaught Error: TypeMismatchError: DOM Exception 17 svg-on-canvas.html:90
toDraw.setter svg-on-canvas.html:90
window.svgButton.render
(anonymous function) svg-on-canvas.html:103
opts.renderCallback jscanvas.js:87
draw canvg.js:2726
svg.loadXmlDoc canvg.js:2733
svg.loadXml canvg.js:2646
canvg canvg.js:62
jsCanvas.compile

Original issue reported on code.google.com by [email protected] on 27 Jun 2013 at 1:27

Attachments:

Repeated ctx.save();ctx.restore() optimization

What steps will reproduce the problem?
1. Generate some SVG
2. Show the generated code ( part )

...
ctx.transform(0.40,0.00,0.00,0.40,284.71,53.57);
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
ctx.restore();
ctx.save();
this.gradients [1] = 
    ctx.createRadialGradient(1352.84,-1234.87,0.00,1352.84,-1234.87,184.97);


What is the expected output? What do you see instead?

ctx.transform(0.40,0.00,0.00,0.40,284.71,53.57);
ctx.restore();
ctx.save();
this.gradients [1] = 
    ctx.createRadialGradient(1352.84,-1234.87,0.00,1352.84,-1234.87,184.97);


Original issue reported on code.google.com by [email protected] on 2 May 2013 at 9:42

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.