Page MenuHomePhabricator

RFC: Items
Open, Incoming QueuePublic


Right now we have Efl.Ui.Default_Item. Which is already stable.
In a unstable context we have: Efl.Ui.List.Placeholder

What do you think of this:

  • Efl.Ui.Standard_Item: A item with single Content). This is just Efl.Ui.List_Placeholder renamed.
  • Efl.Ui.Context_Item: A item which has a single Content part in it. This normal content part can be hidden or slided away in some way (The appearance of that can be defined by the theme). Which then exposes the context part below, which can be used to display some context options. (This sounds simulacra to the decoration mode in genlist, just implemented in a item, so it can be used by others as well)
  • Efl.Ui.Default_Item: (This is just what we have right now)

What do you think of that ?

bu5hm4n created this task.Oct 2 2019, 9:16 AM
bu5hm4n added subscribers: zmike, segfaultxavi, woohyun.

I'm in favor of moving Efl.Ui.List.Placeholder_Item out of List, so it is usable by other people.
I like the idea of bringing genlist's decorations to Unified, but I'm not sure I like the name Context_Item.

The reason for Context here is that you can have the item in context mode, or normal mode. What other names would you like ? (I am bad at nameing ... we all know that ... :P)

cedric added a comment.Oct 4 2019, 1:35 PM

I am not a fan of the name for the proposal as Standard vs Default seems like user of the API could be confused? Like why is default not a standard?

I have a question, if we take it out of List, does it means that whatever position manager we use, it would work?

I am fine with the name and functionality of Efl.Ui.Context_Item.

zmike added a comment.Oct 7 2019, 6:00 AM

I am not a fan of the name for the proposal as Standard vs Default seems like user of the API could be confused? Like why is default not a standard?

This is a good point.

I need a refresher. So we have:

  • Default: an item with Text, Icon and Extra parts.
  • Placeholder: an empty item, meant to be filled by somebody else.
  • Context: An item which shows hidden parts as a result of some action (like swiping or long-pressing).

If the above are correct, how about these alternatives?

  • Default: Default, Standard, Basic.
  • Placeholder: Placeholder (I still like it), Decorator, Empty.
  • Context: Contextual, Complex, Advanced, Screener, Cloaker, Masker.
SanghyeonLee added a comment.EditedNov 11 2019, 11:03 PM
  • Default : I think Default is quite generally used in this case but standard also looks good.
  • Placeholder : I like the Decorator (or Decoratable) as a name, though placeholder is more intuitive.
  • Context : First of all we need to define what exactly this item will do. if it only works with flip(or slide) the item and give another options, Slidable or Hidden_Option can be used. I prefer to have more confirmed type of item not too general and can be understood in many ways.
segfaultxavi added a comment.EditedNov 12 2019, 2:26 AM

The idea is that the Context item will be generic for any kind of item which can have a "hidden" (or "contextual") menu. Sliding is the mechanism used in genlist, but maybe we can think of others.

Any other opinion? This has been stalled for a month now. @bu5hm4n @cedric ?

@SanghyeonLee The more I think about the Placeholder item the less I understand it. Can you tell me what's its purpose? Isn't it exactly like the Default item with empty extra and end parts?

it only hold one swallow part which have the same size of item.
It is just single item container which make user customize their own item without using edc,
so yes, it could be default item if user make an horizontal box and pack the two icon and label. that is the example case I guess.
the idea is,
user may decide the size of item(or their content) by set the min size themselves,
and decorating item as it's own demands.

What I meant is that we do not need the Placeholder item. Users can use the Default item and leave extra and end empty. Is this correct, or am I missing something?

let's guess user want to make an item with progressbar in the center.
or some complicated layout like 3 line text and 3 different check and icon and button.
there are tons of different demands of making their list by their own gui,
we cannot support all of them.

but they can do this by using some container(box, layout, table...) easily.

I think default item is too general and many restrictions that couldn't make it flexibly.
bg, odd/even, underline, all the paddings for icon and text and extra..

the placeholder should be really nothing but a single swallow,
so user need to do everything by themselves.

OK, thanks for the detailed answer. I now understand that the Default item won't always work because of paddings, odd/even coloring, etc.

THEN, back to the topic:

  • Default remains the same (it's already stable).
  • Placeholder remains the same (nothing to do).
  • Context, I don't like it (@bu5hm4n and @cedric like it). Proposed alternatives are: Extended_Item, Extensible_Item, Contextual_Item, Complex_Item, Advanced_Item, Screener_Item, Cloaker_Item, Masker_Item.
SanghyeonLee added a comment.EditedNov 18 2019, 7:55 PM


I'm thinking to adding more item styles,

  • Efl.Ui.Title_Item : the item for title, which can be applied as a header of list.
  • Efl.Ui.List_Double_Label_Item : same as default, but it has two text part vertically, one is text the other one is sub_text, need to think of more about class name and sub text part name though. I don't think this style is necessary for gridview so I restricted in list only.
    • Efl.Ui.Padding_Item : Padding between items. I'm not sure we need this item. It would be better to support padding property in the collection and collectionview, but then we may need a rule of making padding with model property.

These are my thoughts:

  • I think Efl.Ui.Title_Item can be useful. I like the name too.
  • Efl.Ui.List_Double_Label_Item looks useful too. However, I think it will look strange if it is only available for List and not for Grid. We should provide it also for Grids even if it's not commonly used. About the name, how about Efl.Ui.Double_Text_Item, or Efl.Ui.Default_With_Subtitle_Item?
  • I also think item padding should be handled by the container (implementing the Efl.Gfx.Arrangement interface). Inserting items to achieve padding will get messy very soon :)