Re: [PATCH v7 04/10] column: add dense layout support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2012/2/29 Junio C Hamano <gitster@xxxxxxxxx>:
> Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx> writes:
>
>> Normally, all items will be gone through once. The largest cell will set
>> column width for all columns. With this strategy, one long item will
>> stretch out all columns, wasting space in between them.
>>
>> With COL_DENSE enabled, it shrinks all columns to minimum, then attempts
>> to push the last row's cells over to the next column with hope that
>> everything still fits even there's one row less. The process is repeated
>> until the new layout cannot fit in given width anymore, or there's only
>> one row left (perfect!).
>
> As you have given 4 bits for COL_MODE in the previous patch, I expected
> that this will be one of the mode that you can use, e.g. column-first dense,
> or row-first no-dense, with two more bits for operating modes.  Not calling
> it COL_MODE_DENSE and assigning a "are we dense of not?" bit out of COL_MODE
> bits feels wrong.

I reserve the 4 bits for strategies to fill the layout. One day I'm
crazy enough maybe I'll add spiral mode that put the first item in the
center, then next items in a spiral outward. COL_DENSE is about cell
size and should be applicable to any layout strategies. Maybe
COL_LAYOUT_COLUMN, COL_LAYOUT_ROW, COL_WIDTH_DENSE (and
COL_WIDTH_EQUAL) would be better names
-- 
Duy
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]