widget TabButton { layout = HBox; layout = { spacing = -1; } size = 80 0; [vexpand vfill] new Graphic leftEdge { size = 4 21; style.normal = { background = solid(white); image = file("themes/osx/img/tb_left.png"); } style.hover = { background = solid(rgb(.9, .93, 1)); } style.active = { image = file("themes/osx/img/tb_left_active.png"); } } [vexpand vfill hexpand hfill] new Graphic { size = 0 21; style.normal = { background = solid(white); image = grid("themes/osx/img/tb_middle.png", hline(2, 6), vline(0, 21)); } style.hover = { background = solid(rgb(.9, .93, 1)); } style.active = { image = grid("themes/osx/img/tb_middle_active.png", hline(2, 6), vline(0, 21)); } layout = HBox; layout = { padding = 6 0; spacing = 2; } [hexpand vexpand] new HBox leftExtra; [vexpand] new Label label { style.normal = { color = rgb(.1, .1, .1); } } [hexpand vexpand] new HBox rightExtra; } [vexpand vfill] new Graphic rightEdge { size = 4 21; style.normal = { background = solid(white); image = file("themes/osx/img/tb_right.png"); } style.hover = { background = solid(rgb(.9, .93, 1)); } style.active = { image = file("themes/osx/img/tb_right_active.png"); } } leftEdge = sub(leftEdge); rightEdge = sub(rightEdge); leftExtra = sub(leftExtra); rightExtra = sub(rightExtra); label = sub(label); text = prop(label.text); text = "Tab"; } widget TabView { layout = VBox; new HBox tabList { layout = { spacing = -1; } } [hexpand hfill vexpand vfill] new Group clientArea { } tabList = sub(tabList); clientArea = sub(clientArea); }