This support forum belongs to the ImageCropper Gallery Module.
ImageCropper has a bug tracker here: https://github.com/juandopazo/yui3-gallery/issues
| Page 1 of 1 | [ 6 posts ] |
Sebastián Gurin
|
Hello Juan Ignacio, your imagecropper works good. I would like to share with you how your's ImageCropper java code looks in my project http://code.google.com/p/yuigwt/. The example is this http://cancerbero.vacau.com/yuigwt/?test=imageCropper1, you can look at the java sources from there. Also take how it looks ImageCropper Java class API documentation (with UML)
http://cancerbero.vacau.com/yuigwt/javadoc/org/sgx/yuigwt/yuigallery/imagecropper/ImageCropper.html I thought it can be interesting to you to see your creation ported to another language. A Java code fragment Code: String src1 = "http://cabopolonio.com/ovejasenelcabo.jpg"; ImageCropper ic1 = Y.newImageCropper(ImageCropperConfig.create().source(src1). width("743px").height("517px")); ic1.render(parent); ic1.on(ImageCropper.EVENT_CROPEND, new EventCallback<ImageCropperEvent>() { @Override public void call(ImageCropperEvent e) { console.log(e.left()+", "+e.top()+", "+e.width()+", "+e.height()); } }); |
Juan Ignacio DopazoYUI Contributor
|
That's fantastic! Great job!
Due to recent interest in this widget I'm starting to write a User Guide and examples. Here's an early draft: http://juandopazo.github.com/yui3/docs/ ... index.html I'm also working on lowering the byte count a bit. I'm removing a dependency and, as you'll see in the user guide, I'm considering moving keyboard support to a Plugin. It'd be nice to get some feedback on that. Do you think it's worth it or do you prefer to have keyboard support by default? I'm curious about why you're calling Y.newImageCropper instead of new Y.ImageCropper (I know next to nothing about Java). |
Sebastián Gurin
|
Quote: Due to recent interest in this widget I'm starting to write a User Guide and examples. Here's an early draft: http://juandopazo.github.com/yui3/docs/ ... index.html Nice! I hope ImageCropper enters in the set of YUI official modules. Do you know if as a YUI user I can vote to promote your and others gallery modules ? Quote: I'm also working on lowering the byte count a bit. I'm removing a dependency and, as you'll see in the user guide, I'm considering moving keyboard support to a Plugin. It'd be nice to get some feedback on that. Do you think it's worth it or do you prefer to have keyboard support by default? IMHO: lowering load weight making keyboard support optional is good. But I'm not sure about making a plugin for that. Would be this plugin Y.Plugin.ImageCropperKeys usable on other modules / scenarios other than the image cropper ? Perhaps it would be better to make a plugin Y.Plugin.ResizeKeys, a plugin that can be plugged to a Resize so Resize could support keys. This way ImageCropper only have to delegate the plugin to its Resize and others can use it with their own resizes... Just my thougts. Quote: I'm curious about why you're calling Y.newImageCropper instead of new Y.ImageCropper (I know next to nothing about Java). That is a long story This of course have some consequences, and the biggest is that all the yuigwt objects are currently native JavaScript YUI objects, created by native Javascript YUI and not created in java. I cannot write in java "new Y.ImageCropper" because the image cropper instance must be created by the native JavaScript YUI not by the java code. Well I'm documenting some notes about this kind of things in http://code.google.com/p/yuigwt/wiki/YUIJavaApi Regards |
Juan Ignacio DopazoYUI Contributor
|
Cancerbero wrote: Nice! I hope ImageCropper enters in the set of YUI official modules. Do you know if as a YUI user I can vote to promote your and others gallery modules ? I think it's all very informal at the moment. If the module gets enough usage I'll send a pull request to the core library and see what the YUI developers think. Cancerbero wrote: Would be this plugin Y.Plugin.ImageCropperKeys usable on other modules / scenarios other than the image cropper ? Perhaps it would be better to make a plugin Y.Plugin.ResizeKeys, a plugin that can be plugged to a Resize so Resize could support keys. This way ImageCropper only have to delegate the plugin to its Resize and others can use it with their own resizes... Just my thougts. Actually, another reason I'm considering moving it to a Plugin is that keys only work for dragging. Resizing with the keyboard wasn't supported by the YUI2 ImageCropper so I didn't write it. Y.Plugin.DragKeys makes sense. I'll play around with that idea and see how it works with Y.Plugin.DDConstrain. Cancerbero wrote: That is a long story Very interesting! |
Sebastián Gurin
|
Quote: Actually, another reason I'm considering moving it to a Plugin is that keys only work for dragging. Resizing with the keyboard wasn't supported by the YUI2 ImageCropper so I didn't write it. Y.Plugin.DragKeys makes sense. I'll play around with that idea and see how it works with Y.Plugin.DDConstrain. Yes, I get confused, I meant Y.PluginDragKeys. That would be nice, and you can make it in a separate module so others can use it in other scenarios. Regards |
Sebastián Gurin
|
About the hipotetical Y.Plugin.DragKeys, It would be nice to be able to perform this:
aDrag.plug(Y.Plugin.DragKeys, { modifier: ["alt"], throttle: 200 }) modifier : for indicating to react to key presses only when a certain modifier key like alt or ctrl is pressed. throttle: for using Y.throttle when the user left an arrow key pressed . http://yuilibrary.com/yui/docs/api/clas ... d_throttle |
| Page 1 of 1 | [ 6 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group