| 4061 | /* List all the files now in the table. */ |
| 4062 | |
| 4063 | static void |
| 4064 | print_current_files (void) |
| 4065 | { |
| 4066 | switch (format) |
| 4067 | { |
| 4068 | case one_per_line: |
| 4069 | for (idx_t i = 0; i < cwd_n_used; i++) |
| 4070 | { |
| 4071 | print_file_name_and_frills (sorted_file[i], 0); |
| 4072 | putchar (eolbyte); |
| 4073 | } |
| 4074 | break; |
| 4075 | |
| 4076 | case many_per_line: |
| 4077 | if (! line_length) |
| 4078 | print_with_separator (' '); |
| 4079 | else |
| 4080 | print_many_per_line (); |
| 4081 | break; |
| 4082 | |
| 4083 | case horizontal: |
| 4084 | if (! line_length) |
| 4085 | print_with_separator (' '); |
| 4086 | else |
| 4087 | print_horizontal (); |
| 4088 | break; |
| 4089 | |
| 4090 | case with_commas: |
| 4091 | print_with_separator (','); |
| 4092 | break; |
| 4093 | |
| 4094 | case long_format: |
| 4095 | for (idx_t i = 0; i < cwd_n_used; i++) |
| 4096 | { |
| 4097 | set_normal_color (); |
| 4098 | print_long_format (sorted_file[i]); |
| 4099 | dired_outbyte (eolbyte); |
| 4100 | } |
| 4101 | break; |
| 4102 | } |
| 4103 | } |
| 4104 | |
| 4105 | /* Replace the first %b with precomputed aligned month names. |
| 4106 | Note on glibc-2.7 at least, this speeds up the whole 'ls -lU' |
no test coverage detected