-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Question about signature size vs canvas size #248
Comments
Yes, it worked for me before some changes, and I think is the better way for responsive designs:
And before submiting the data to database I do this:
|
i have tried your method but its not working may be i am using it differently. could you please make plunker how you have done it ? |
@RajuKottedi yes, and I'm interested if you find a better way also. I'm using FacturaScripts and it uses RainTPL, all mentions to {$fsc->vars} are equivalent to $this->vars on the controller side. This is my full script block on view: Using this way, works great on all devices, but the saved image was scaled on redraw , and I'm interested to only scale it when was loaded on a different device with different aspect ratio that require it. Has no sense for me obtain a different aspect ratio before and after save, but at least, is working. Share any progress you get ;) |
@shawe thanks for the code. Will let you know if there is any progress :) |
I'm using this function #49 (comment) shared by @jaredatch that crop the user signature without whitespace.
My code now is like this, for always resize and draw, that in my opinion is not correctly explained on your example: #33 (comment) and this caused a lot of issues reported here.
I based my code in your example code but I'm using BootStrap for responsiveness and the canvas size can be set different width/height for any device, and signature is always set with canvas size, without respecting the stored canvas size and aspect ratio. Is there a way to change this behavior? In other words, I prefer to get a scaled signatured inside of canvas used by signature_pad.
For example, this can help me: #153 (comment) ?
The text was updated successfully, but these errors were encountered: