Thanks for the comment, ccc.
I will take a look at ui scene module as well.
Welcome!
This is the community forum for my apps Pythonista and Editorial.
For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.
Latest posts made by AlexKudrenko
-
RE: Resizing the portrait-oriented images rotates it to 90° degrees.
-
Resizing the portrait-oriented images rotates it to 90° degrees.
Hi. I'm trying to write a script to resize the image to 1200 pixels wide.
Everything seems to be working fine apart from the fact that all portrait-oriented photos are rotated 90° degrees.The images are displayed correctly (in portrait orientation) in my camera roll.
But when I'm running the script they are rotated 90° degrees to landscape mode.
What am I doing wrong here?
Here is the script I'm using.
from PIL import Image import photos import console image = photos.pick_image() def customSize(image): w, h = image.size print 'Original image size: '+str(w)+' × '+str(h)+' pixels'+'\n' if w > 1200: wsize = 1200/float(w) hsize = int(float(h)*float(wsize)) image = image.resize((1200, hsize), Image.ANTIALIAS) print 'Modified image size: 1200 × '+str(hsize)+' pixels' else: print 'Image is too small to be resampled. Width is less than 1200 pixels' return image image = customSize(image) image.show() saveit = photos.save_image(image) print 'Done!'
-
RE: Resizing the portrait-oriented images rotates it to 90° degrees.
Thanks, omz. <code>original=False</code> helped. The only downside is that the image is already scaled to less than 1200 pixels (as you've said).
It still will work for me though.
I will take a look metadata option when have a little bit more free time :)Thanks again.
-
Append clipboard to existing file & return back to Drafts
Hi, I'm trying to create a workflow that will append a clipboard (generated in Drafts 4) to the existing file and then return back to Drafts.
Right now it looks like that.
editorial://open/<filename>?root=Dropbox&command=Append&x-success=drafts://
Editorial command
Append
just appends a clipboard.I've got everything working apart from return back to Drafts part. The clipboard gets appended to the file but nothing happens after that.
What am I missing?
-
RE: Append clipboard to existing file & return back to Drafts
Yes!!! That's the reason. Thanks omz.