macOS-like truncation of filenames

Features wanted...
Post Reply
John_C
Posts: 336
Joined: 16 May 2018 20:04

macOS-like truncation of filenames

Post by John_C »

On Windows, when the filename is too long, it truncates on the right side:

Code: Select all

a very long filename
a_b_c_d_e_f_g_h_i_j_k_l_m_n_o_p_q_r_s_t_u_v_w_x_y_z.txt
will be displayed as
a_b_c_d_e_f_g_h_i_j...
On macOS, it will be something like

Code: Select all

a_b_c_d...w_x_y_z.txt
That is, the truncation performed in the middle.

admin
Site Admin
Posts: 60558
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: macOS-like truncation of filenames

Post by admin »

What's the advantage? Seeing the extension? Seeing the end of the base name? Yes, that might be a good idea. What do others think?

klownboy
Posts: 4139
Joined: 28 Feb 2012 19:27

Re: macOS-like truncation of filenames

Post by klownboy »

I don't use a Apple product other than an iPad occasionally I got as a steep discount. It's a good idea in my opinion, since as you mentioned, you're able to see the file extension. That's an important part in seeing a long filename especially when some folders have identical file base names with different extensions.
Windows 11, 23H2 Build 22631.3447 at 100% 2560x1440

admin
Site Admin
Posts: 60558
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: macOS-like truncation of filenames

Post by admin »

I personally have the Ext column always visible so I don't need to see the extension here. But I often have interesting info at the end of the base name, like dates or serial numbers. So I would welcome that truncation option as well.

Marco
Posts: 2347
Joined: 27 Jun 2011 15:20

Re: macOS-like truncation of filenames

Post by Marco »

admin wrote: 23 Mar 2020 18:54 I personally have the Ext column always visible so I don't need to see the extension here. But I often have interesting info at the end of the base name, like dates or serial numbers. So I would welcome that truncation option as well.
Very same here, so definitely +1
Tag Backup - SimpleUpdater - XYplorer Messenger - The Unofficial XYplorer Archive - Everything in XYplorer
Don sees all [cit. from viewtopic.php?p=124094#p124094]

admin
Site Admin
Posts: 60558
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: macOS-like truncation of filenames

Post by admin »

Done. 8)

klownboy
Posts: 4139
Joined: 28 Feb 2012 19:27

Re: macOS-like truncation of filenames

Post by klownboy »

I like it especially since I don't use an "ext" column. It's allows me to cut down the size of the name column a bit. :tup:
Windows 11, 23H2 Build 22631.3447 at 100% 2560x1440

prino
Posts: 337
Joined: 18 Mar 2012 21:14
Location: Vilnius, Lithuania
Contact:

Re: macOS-like truncation of filenames

Post by prino »

Funny, this is what PL/I on z/OS has been doing, for about a zillion years, with names that are too long for the limit (7 chars) on external names:

Code: Select all

CSECTCUT(n)
The CSECTCUT option controls how the compiler, when processing the CSECT
option, handles long names.

The CSECTCUT option has no effect unless you specify the CSECT option. It also
has no effect if the "package name" used by the CSECT option has 7 or fewer
characters.
The value n in the CSECTCUT option must be between 0 and 7, the default is 4.

If the "package name" used by the CSECT option has more than 7 characters, the
compiler will collapse the name to 7 characters by taking the first n and last 7 - n
characters.

For example, consider a compilation consisting of one procedure with the name
BEISPIEL:

v Under CSECTCUT(3), the compiler collapses the name to BEIPIEL.
v Under CSECTCUT(4), the compiler collapses the name to BEISIEL.
Robert AH Prins
robert.ah.prins @ the.17+Gb.Google thingy
At last, a tiny bit of programming here... :mrgreen:

Post Reply