Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
98d7abb
commit 0158d75
Showing
4 changed files
with
235 additions
and
0 deletions.
There are no files selected for viewing
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,198 @@ | ||
using Gtk 4.0; | ||
using Adw 1; | ||
|
||
Adw.StatusPage { | ||
title: _("Frame"); | ||
description: _("A widget that surrounds its child with a decorative frame"); | ||
|
||
Box { | ||
orientation: vertical; | ||
halign: center; | ||
|
||
Box { | ||
orientation: horizontal; | ||
halign: center; | ||
spacing: 18; | ||
margin-bottom: 18; | ||
homogeneous: false; | ||
|
||
Box { | ||
orientation: vertical; | ||
halign: center; | ||
spacing: 12; | ||
|
||
Picture without_frame { | ||
width-request: 180; | ||
height-request: 180; | ||
} | ||
|
||
Label { | ||
label: _("Without Frame"); | ||
styles ["title-4"] | ||
} | ||
|
||
} | ||
|
||
Separator { | ||
margin-start: 6; | ||
margin-end: 6; | ||
} | ||
|
||
Box { | ||
orientation: vertical; | ||
halign: center; | ||
spacing: 12; | ||
|
||
Frame { | ||
|
||
Picture with_frame { | ||
width-request: 180; | ||
height-request: 180; | ||
} | ||
} | ||
|
||
Label { | ||
label: _("With Frame"); | ||
styles ["title-4"] | ||
} | ||
} | ||
} | ||
|
||
Separator { | ||
margin-bottom: 24; | ||
} | ||
|
||
Label { | ||
label: _("Without Frame"); | ||
margin-bottom: 12; | ||
halign: start; | ||
styles ["title-4"] | ||
} | ||
|
||
Box { | ||
margin-bottom: 18; | ||
halign: center; | ||
styles ["toolbar"] | ||
|
||
Button { | ||
icon-name: "plus"; | ||
} | ||
|
||
Button { | ||
icon-name: "minus"; | ||
} | ||
|
||
Button { | ||
icon-name: "bell"; | ||
} | ||
} | ||
|
||
Label { | ||
halign: start; | ||
label: _("With Frame"); | ||
margin-bottom: 12; | ||
styles ["title-4"] | ||
} | ||
|
||
|
||
Frame { | ||
label: _("Frame can have an optional label"); | ||
margin-bottom: 24; | ||
|
||
Box { | ||
halign: center; | ||
styles ["toolbar"] | ||
|
||
Button { | ||
icon-name: "plus"; | ||
} | ||
|
||
Button { | ||
icon-name: "minus"; | ||
} | ||
|
||
Button { | ||
icon-name: "bell"; | ||
} | ||
} | ||
} | ||
|
||
Separator { | ||
margin-bottom: 24; | ||
} | ||
|
||
Box { | ||
orientation: horizontal; | ||
halign: center; | ||
spacing: 18; | ||
margin-bottom: 18; | ||
homogeneous: false; | ||
|
||
Box { | ||
orientation: vertical; | ||
halign: center; | ||
spacing: 12; | ||
|
||
ScrolledWindow { | ||
height-request: 240; | ||
width-request: 240; | ||
|
||
TextView textview_without_frame { | ||
bottom-margin: 12; | ||
left-margin: 12; | ||
right-margin: 12; | ||
top-margin: 12; | ||
margin-bottom: 12; | ||
editable: false; | ||
wrap-mode: char; | ||
} | ||
} | ||
|
||
Label { | ||
label: _("Without Frame"); | ||
styles ["title-4"] | ||
} | ||
} | ||
|
||
Separator { | ||
margin-start: 6; | ||
margin-end: 6; | ||
} | ||
|
||
Box { | ||
orientation: vertical; | ||
halign: center; | ||
spacing: 12; | ||
|
||
Frame { | ||
|
||
ScrolledWindow { | ||
height-request: 240; | ||
width-request: 240; | ||
|
||
TextView textview_with_frame { | ||
bottom-margin: 12; | ||
left-margin: 12; | ||
right-margin: 12; | ||
top-margin: 12; | ||
editable: false; | ||
wrap-mode: char; | ||
} | ||
} | ||
} | ||
|
||
Label { | ||
label: _("With Frame"); | ||
styles ["title-4"] | ||
} | ||
} | ||
} | ||
|
||
LinkButton { | ||
label: "API Reference"; | ||
uri: "https://docs.gtk.org/gtk4/class.Frame.html"; | ||
} | ||
} | ||
} | ||
|
||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"name": "Frame", | ||
"category": "layout", | ||
"description": "A widget that surrounds its child with a decorative frame", | ||
"panels": [ | ||
"ui", | ||
"preview" | ||
], | ||
"autorun": true | ||
} |