nglauber
07/03/2020, 6:08 PMLeland Richardson [G]
07/03/2020, 6:10 PMLeland Richardson [G]
07/03/2020, 6:11 PMAdam Powell
07/03/2020, 6:11 PMLeland Richardson [G]
07/03/2020, 6:12 PMLeland Richardson [G]
07/03/2020, 6:12 PMLeland Richardson [G]
07/03/2020, 6:12 PMLeland Richardson [G]
07/03/2020, 6:12 PMLeland Richardson [G]
07/03/2020, 6:13 PMAdam Powell
07/03/2020, 6:13 PMSpacerLeland Richardson [G]
07/03/2020, 6:13 PMLeland Richardson [G]
07/03/2020, 6:13 PMAdam Powell
07/03/2020, 6:14 PMLeland Richardson [G]
07/03/2020, 6:14 PMAdam Powell
07/03/2020, 6:15 PMnglauber
07/03/2020, 6:15 PMLeland Richardson [G]
07/03/2020, 6:15 PMAdam Powell
07/03/2020, 6:16 PMLeland Richardson [G]
07/03/2020, 6:16 PMAdam Powell
07/03/2020, 6:16 PMLeland Richardson [G]
07/03/2020, 6:17 PMLeland Richardson [G]
07/03/2020, 6:17 PMAdam Powell
07/03/2020, 6:18 PMnglauber
07/03/2020, 6:20 PMLeland Richardson [G]
07/03/2020, 6:20 PMAdam Powell
07/03/2020, 6:21 PMPaddingLeland Richardson [G]
07/03/2020, 6:21 PMI feel like we do have solid definitions for these thingsIf we do, I have not seen them. I think most of us understand how the system works, but we haven’t solidifed names for what the conceptual “box” of a modifier in a modifier chain is, and what the thing to the “right” and “left” of it is referred to. Most of the terms we use end up having ambiguities but we sludge through it because we can glean just enough based on context of what the person is talking about
Adam Powell
07/03/2020, 6:23 PMMeasurablePlaceablenglauber
07/03/2020, 6:30 PMLeland Richardson [G]
07/03/2020, 6:34 PMLeland Richardson [G]
07/03/2020, 6:35 PMnglauber
07/03/2020, 6:35 PMnglauber
07/03/2020, 6:39 PMRow(
    modifier = Modifier.drawBackground(color = Color.Red)
        .padding(16.dp)
//                .margin(16.dp)
) {
   Text("1")
    Text("2")
    Text("3")
}RowLeland Richardson [G]
07/03/2020, 6:40 PMLeland Richardson [G]
07/03/2020, 6:40 PMAdam Powell
07/03/2020, 6:41 PMLayoutParamsmarginLeland Richardson [G]
07/03/2020, 6:41 PMAdam Powell
07/03/2020, 6:41 PMLeland Richardson [G]
07/03/2020, 6:42 PMLeland Richardson [G]
07/03/2020, 6:42 PMLeland Richardson [G]
07/03/2020, 6:42 PMAdam Powell
07/03/2020, 6:43 PMLeland Richardson [G]
07/03/2020, 6:43 PMLeland Richardson [G]
07/03/2020, 6:44 PMAdam Powell
07/03/2020, 6:45 PMAdam Powell
07/03/2020, 6:45 PMAdam Powell
07/03/2020, 6:46 PMLeland Richardson [G]
07/03/2020, 6:47 PMhenrikhorbovyi
07/03/2020, 7:05 PMhenrikhorbovyi
07/03/2020, 7:06 PMAdam Powell
07/03/2020, 7:08 PMandroid:layout_weightAdam Powell
07/03/2020, 7:12 PMhenrikhorbovyi
07/03/2020, 7:18 PMSergey Y.
07/03/2020, 7:52 PMLayoutParamsLeland Richardson [G]
07/03/2020, 8:06 PMnglauber
07/03/2020, 10:43 PMModifierpaddingdagomni
07/03/2020, 10:47 PM"[...] I find that most people will just write the code that feels the most natural and its "good enough" most of the time. We want Compose to be the same way. [...]".
Even though with "good enough" you meant performance, I think that in general Compose is the way to make writing UI as much a natural process as it can be. And margins are ingrained in developers' minds, not only on Android, so when we have only padding, something will always be missing. I feel that it's easier to think about either just spacing or margins + padding.
pavi2410
07/04/2020, 12:16 PMpavi2410
07/04/2020, 12:19 PMAdam Powell
07/04/2020, 12:57 PMAdam Powell
07/04/2020, 1:11 PMAdam Powell
07/04/2020, 1:15 PMAdam Powell
07/04/2020, 1:19 PMAdam Powell
07/04/2020, 1:23 PMAdam Powell
07/04/2020, 1:26 PMAdam Powell
07/04/2020, 1:33 PMAdam Powell
07/04/2020, 1:36 PMAdam Powell
07/04/2020, 1:37 PMBoxAdam Powell
07/04/2020, 1:37 PMAdam Powell
07/04/2020, 1:40 PMModifier.boxBoxpavi2410
07/04/2020, 1:57 PM@Composable
fun BoxModel() {
    Box(
        modifier = Modifier // applies from outside (left) to inside (right)
            .size(100.dp)
            .drawBackground(Color.Red).padding(4.dp)   // margin
            .drawBorder(1.dp, Color.Black)             // border
            .drawBackground(Color.Green).padding(8.dp) // padding
    ) {
        Box(modifier = Modifier.drawBackground(Color.Blue).fillMaxSize())
    }
}pavi2410
07/04/2020, 1:57 PMAdam Powell
07/04/2020, 2:03 PMBoxSpacerTextButtonVinay Gaba
07/12/2020, 4:41 AMAdam Powell
07/12/2020, 5:34 AMVinay Gaba
07/12/2020, 5:01 PM