Skip to content

Commit

Permalink
4.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
TeaM-TL committed Sep 10, 2023
1 parent 09ca81f commit 04952a7
Show file tree
Hide file tree
Showing 5 changed files with 383 additions and 250 deletions.
2 changes: 2 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## 2023

4.4.1 Fix compose preview, update fotokilof.pot and pl translations

4.4.0 Added compose two pictures, removed histogram from code

4.3.3 Italian translation, __main__.py instead fotokilof.py
Expand Down
22 changes: 12 additions & 10 deletions fotokilof/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,8 +201,11 @@ def preview_orig_button():
def preview_new_button():
""" preview new picture """
# to define file_out
if os.path.isfile(path_to_file_out(resized.get())):
convert_wand.display_image(path_to_file_out(resized.get()))
try:
if os.path.isfile(path_to_file_out(resized.get())):
convert_wand.display_image(path_to_file_out(resized.get()))
except:
log.write_log("No result picture to preview", "W")


def compose_preview_button():
Expand All @@ -211,7 +214,6 @@ def compose_preview_button():
convert_wand.display_image(img_compose_file.get())
except:
log.write_log("No compose picture to preview", "W")
print('fix it: compose_preview_button')


def extension_from_file():
Expand Down Expand Up @@ -600,6 +602,7 @@ def compose_autoresize():
frame_compose_autoresize.grid_remove()
else:
frame_compose_autoresize.grid()
compose_autoresize_gravity()


def compose_autoresize_gravity():
Expand Down Expand Up @@ -2454,15 +2457,15 @@ def text_tool_hide_show():
bootstyle="outline",
command=color_choose_compose)
l_compose_color = Label(frame_compose_autoresize, text=_(" "))
rb_compose_N = ttk.Radiobutton(frame_compose_autoresize, text="Top",
rb_compose_N = ttk.Radiobutton(frame_compose_autoresize, text=_("Top"),
variable=img_compose_gravity, value="N")
rb_compose_W = ttk.Radiobutton(frame_compose_autoresize, text="Left",
rb_compose_W = ttk.Radiobutton(frame_compose_autoresize, text=_("Left"),
variable=img_compose_gravity, value="W")
rb_compose_C = ttk.Radiobutton(frame_compose_autoresize, text=_("Center"),
variable=img_compose_gravity, value="C")
rb_compose_E = ttk.Radiobutton(frame_compose_autoresize, text="Right",
rb_compose_E = ttk.Radiobutton(frame_compose_autoresize, text=_("Right"),
variable=img_compose_gravity, value="E")
rb_compose_S = ttk.Radiobutton(frame_compose_autoresize, text="Bottom",
rb_compose_S = ttk.Radiobutton(frame_compose_autoresize, text=_("Bottom"),
variable=img_compose_gravity, value="S")

b_compose_color.grid(padx=5, pady=5, row=1, column=1)
Expand Down Expand Up @@ -2581,7 +2584,7 @@ def text_tool_hide_show():
# binding commands to widgets
co_preview_selector_orig.bind("<<ComboboxSelected>>", preview_orig_refresh)
co_preview_selector_new.bind("<<ComboboxSelected>>", preview_new_refresh)
co_preview_selector_new.bind("<<ComboboxSelected>>", preview_new_refresh)
co_compose_preview_selector.bind("<<ComboboxSelected>>", preview_compose_refresh)
co_text_font.bind("<<ComboboxSelected>>", font_selected)
c_preview_orig_pi.bind("<Button-1>", mouse_crop_nw)
if mswindows.macos():
Expand Down Expand Up @@ -2734,8 +2737,7 @@ def text_tool_hide_show():
ToolTip(rb_compose_E, text=_("Join picture at bottom and move to right"))
ToolTip(rb_compose_S, text=_("Join picture on right and move to bottom"))
ToolTip(b_compose_run, text=_("Execute compose picture with current main picture"))


ToolTip(b_preview_new_run, text=_("Display image to join by IMdisplay or default image viewer of OS"))

##########################################
# Run functions
Expand Down
Loading

0 comments on commit 04952a7

Please sign in to comment.