[Gimp-user] How to get the positions(x, y) (width, depth) of selected rectangle or selected ellipse
- From: tamasakai <forums gimpusers com>
- To: gimp-user-list gnome org
- Subject: [Gimp-user] How to get the positions(x, y) (width, depth) of selected rectangle or selected ellipse
- Date: Mon, 17 Feb 2020 01:52:40 +0100
Dear Ofnuts. Thanks! ;) There was a good way!
Is it OK?
2020年2月14日(金) 16:34 Ofnuts <ofnuts gmx com>:
Thank you for all members replied to my questions.
I am jast a biginner of GIMP.
So please tell me step by step with patience.
Then, I wrote a script, made a image named "sample.xcf" and made a rectangle
selection on it.
The script on Python Consol made errors.
What should I do next?
--------------------------------
# How to get the positions(x, y) (width, depth) of selected rectangle or
selected ellipse
(non_empty,x1,y1,x2,y2) = selection_bounds (sample.xcf)
with open(file_name, 'w') as f:
writer = csv.writer(f)
writer.writerow([x1, y1, x2, y2])
main()
------------------------------
--
tamasakai (via www.gimpusers.com/forums)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]