Set tab length per dir title len
This commit is contained in:
parent
67b209e57b
commit
710d37f01d
@ -115,8 +115,12 @@ class TabMixin(WidgetMixin):
|
||||
if not traversed:
|
||||
return
|
||||
|
||||
|
||||
self.load_store(view, store)
|
||||
self.set_path_text(wid, tid)
|
||||
|
||||
char_width = len(view.get_end_of_path())
|
||||
tab_label.set_width_chars(char_width)
|
||||
tab_label.set_label(view.get_end_of_path())
|
||||
self.set_window_title()
|
||||
self.set_file_watcher(view)
|
||||
|
@ -90,9 +90,9 @@ class WidgetMixin:
|
||||
icon = Gtk.Image(stock=Gtk.STOCK_CLOSE)
|
||||
|
||||
label.set_label(f"{view.get_end_of_path()}")
|
||||
label.set_width_chars(25)
|
||||
label.set_max_width_chars(64)
|
||||
label.set_ellipsize(2) #PANGO_ELLIPSIZE_MIDDLE
|
||||
label.set_width_chars(len(view.get_end_of_path()))
|
||||
label.set_xalign(0.0)
|
||||
# label.set_ellipsize(2) #PANGO_ELLIPSIZE_MIDDLE
|
||||
tid.set_label(f"{view.id}")
|
||||
|
||||
close.add(icon)
|
||||
|
Loading…
Reference in New Issue
Block a user