Skip to content

Commit

Permalink
Merge branch 'master' into diagramwidget
Browse files Browse the repository at this point in the history
  • Loading branch information
pbrown12303 authored Jul 26, 2023
2 parents db73a10 + ad10f34 commit b19c2e6
Show file tree
Hide file tree
Showing 16 changed files with 914 additions and 73 deletions.
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,10 @@ Community contributed widgets.

A widget that will run animated gifs.

<p align="center" class="align:center;margin:auto" markdown="1">
<img src="img/gifwidget.gif" />
</p>

```go
gif, err := NewAnimatedGif(storage.NewFileURI("./testdata/gif/earth.gif"))
gif.Start()
Expand All @@ -70,7 +74,7 @@ gif.Start()

A date picker which returns a [time](https://pkg.go.dev/time) object with the selected date.

<p align="center" class="align:center;margin:auto">
<p align="center" class="align:center;margin:auto">

<img src="https://user-images.githubusercontent.com/45520351/179398051-a1f961fd-64be-4214-a565-0da85ce4a543.png" style="max-width: 100%" alt="Calendar widget"/>

Expand Down Expand Up @@ -321,3 +325,24 @@ for validation using an entropy system.
pw := validation.NewPassword(70) // Minimum password entropy allowed defined as 70.
```

## Themes

### Adwaita

Adwaita is the theme used in new the versions of KDE and Gnome (and derivatives) on GNU/Linux.
This theme proposes a color-schme taken from the Adwaita scpecification.

Use it with:

```go
import "fyne.io/x/fyne/theme"
//...

app := app.New()
app.Settings().SetTheme(theme.AdwaitaTheme())
```

![Adwaita Dark](./img/adwaita-theme-dark.png)

![Adwaita Light](./img/adwaita-theme-light.png)

10 changes: 5 additions & 5 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ go 1.14

require (
fyne.io/fyne/v2 v2.3.5
github.com/Andrew-M-C/go.jsonvalue v1.3.3
github.com/eclipse/paho.mqtt.golang v1.4.2
github.com/gorilla/websocket v1.5.0
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646
github.com/srwiley/rasterx v0.0.0-20210519020934-456a8d69b780
github.com/stretchr/testify v1.8.2
github.com/twpayne/go-geom v1.5.2
github.com/Andrew-M-C/go.jsonvalue v1.1.2-0.20211223013816-e873b56b4a84
github.com/eclipse/paho.mqtt.golang v1.3.5
github.com/gorilla/websocket v1.4.2
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646
github.com/stretchr/testify v1.8.0
github.com/wagslane/go-password-validator v0.3.0
golang.org/x/image v0.3.0
)
24 changes: 13 additions & 11 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ fyne.io/fyne/v2 v2.3.5 h1:Q8WOtsms+esLrBKJGdj6P+klu+UXzRq63uPxFSQm4nc=
fyne.io/fyne/v2 v2.3.5/go.mod h1:fbrL+kwOQ6sdVhnURktTHIRIEXwysQSLeejyFyABmNI=
fyne.io/systray v1.10.1-0.20230602210930-b6a2d6ca2a7b h1:MP1cUnIdF1cxrMhK9iw9H0JP3zopyD1zi84BqU6WTsE=
fyne.io/systray v1.10.1-0.20230602210930-b6a2d6ca2a7b/go.mod h1:oM2AQqGJ1AMo4nNqZFYU8xYygSBZkW2hmdJ7n4yjedE=
github.com/Andrew-M-C/go.jsonvalue v1.3.3 h1:zPTwpjYwNmqHMyIWyES++xm4k5k1bkdtZoU620pxjEc=
github.com/Andrew-M-C/go.jsonvalue v1.3.3/go.mod h1:IwnJ6++SYu/lYAvrJCGGCd9WaT0zTcsD6Li1X9IHcSU=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E=
github.com/Andrew-M-C/go.jsonvalue v1.1.2-0.20211223013816-e873b56b4a84 h1:L2C3QKBQwuHuiKwaBj8HDs2r0bAUGqtBYe3ymG0S6Z4=
github.com/Andrew-M-C/go.jsonvalue v1.1.2-0.20211223013816-e873b56b4a84/go.mod h1:oTJGG91FhtsxvUFVwHSvr6zuaTcAuroj/ToxfT7Ox8U=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/BurntSushi/toml v1.1.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ=
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
Expand Down Expand Up @@ -345,10 +345,11 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8=
github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk=
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww=
github.com/tevino/abool v1.2.0 h1:heAkClL8H6w+mK5md9dzsuohKeXHUpY7Vw0ZCKW+huA=
Expand Down Expand Up @@ -485,9 +486,10 @@ golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLd
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=
golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b h1:PxfKdU9lEEDYjdIzOtC4qFWgkU2rGHdKlKowJSMN9h0=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
Expand Down Expand Up @@ -565,19 +567,18 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210906170528-6f6e22806c34/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211116061358-0a5406a5449c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220405210540-1e041c57c461/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU=
golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k=
golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k=
golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
Expand All @@ -587,9 +588,10 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo=
golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/text v0.6.0 h1:3XmdazWV+ubf7QgHSTWeykHOci5oeekaGJBLkrkaw4k=
golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
Expand Down
Binary file added img/adwaita-theme-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/adwaita-theme-light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/gifwidget.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/hexwidget_00abcdef.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/hexwidget_12345678.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 13 additions & 11 deletions layout/responsive.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ type responsiveConfig map[responsiveBreakpoint]float32
// newResponsiveConf return a new responsive configuration.
// The optional ratios must
// be 0 < ratio <= 1 and passed in this order:
// Responsive(object, smallRatio, mediumRatio, largeRatio, xlargeRatio)
//
// Responsive(object, smallRatio, mediumRatio, largeRatio, xlargeRatio)
//
// They are set to previous value if a value is not passed, or 1.0 if there is no previous value.
func newResponsiveConf(ratios ...float32) responsiveConfig {
responsive := responsiveConfig{}
Expand Down Expand Up @@ -232,12 +234,13 @@ func (resp *ResponsiveLayout) maxFloat32(a, b float32) float32 {
// configure the rule, each object could be encapsulated by a "Responsive" object.
//
// Example:
// container := NewResponsiveLayout(
// Responsive(label, 1, .5, .25), // 100% for small, 50% for medium, 25% for large
// Responsive(button, 1, .5, .25), // ...
// label2, // this will be placed and resized with default behaviors
// // => 1, 1, 1
// )
//
// container := NewResponsiveLayout(
// Responsive(label, 1, .5, .25), // 100% for small, 50% for medium, 25% for large
// Responsive(button, 1, .5, .25), // ...
// label2, // this will be placed and resized with default behaviors
// // => 1, 1, 1
// )
func NewResponsiveLayout(o ...fyne.CanvasObject) *fyne.Container {
r := &ResponsiveLayout{}

Expand All @@ -264,7 +267,9 @@ var _ fyne.Widget = (*responsiveWidget)(nil)
// Responsive register the object with a responsive configuration.
// The optional ratios must
// be 0 < ratio <= 1 and passed in this order:
// Responsive(object, smallRatio, mediumRatio, largeRatio, xlargeRatio)
//
// Responsive(object, smallRatio, mediumRatio, largeRatio, xlargeRatio)
//
// They are set to previous value if a value is not passed, or 1.0 if there is no previous value.
// The returned object is not modified.
func Responsive(object fyne.CanvasObject, breakpointRatio ...float32) fyne.CanvasObject {
Expand All @@ -277,8 +282,5 @@ func (ro *responsiveWidget) CreateRenderer() fyne.WidgetRenderer {
if ro.render == nil {
return nil
}
if o, ok := ro.render.(fyne.Widget); ok {
return o.CreateRenderer()
}
return widget.NewSimpleRenderer(ro.render)
}
52 changes: 52 additions & 0 deletions theme/adwaita.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
package theme

import (
"image/color"

"fyne.io/fyne/v2"
"fyne.io/fyne/v2/theme"
)

// must be in sync with adwaita_colors_generator.go - getting the colors from the Adwaita document page.
//go:generate go run ./adwaita_colors_generator.go

var _ fyne.Theme = (*Adwaita)(nil)

// AdwaitaTheme returns a new Adwaita theme.
func AdwaitaTheme() fyne.Theme {
return &Adwaita{}
}

// Adwaita is a theme that follows the Adwaita theme.
// See: https://gnome.pages.gitlab.gnome.org/libadwaita/doc/main/named-colors.html
type Adwaita struct{}

// Color returns the named color for the current theme.
func (a *Adwaita) Color(name fyne.ThemeColorName, variant fyne.ThemeVariant) color.Color {
switch variant {
case theme.VariantLight:
if c, ok := adwaitaLightScheme[name]; ok {
return c
}
case theme.VariantDark:
if c, ok := adwaitaDarkScheme[name]; ok {
return c
}
}
return theme.DefaultTheme().Color(name, variant)
}

// Font returns the named font for the current theme.
func (a *Adwaita) Font(style fyne.TextStyle) fyne.Resource {
return theme.DefaultTheme().Font(style)
}

// Icon returns the named resource for the current theme.
func (a *Adwaita) Icon(name fyne.ThemeIconName) fyne.Resource {
return theme.DefaultTheme().Icon(name)
}

// Size returns the size of the named resource for the current theme.
func (a *Adwaita) Size(name fyne.ThemeSizeName) float32 {
return theme.DefaultTheme().Size(name)
}
60 changes: 60 additions & 0 deletions theme/adwaita_colors.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
package theme

// This file is generated by adwaita_colors_generator.go
// Please do not edit manually, use:
// go generate ./theme/...
//
// The colors are taken from: https://gnome.pages.gitlab.gnome.org/libadwaita/doc/1.0/named-colors.html

import (
"image/color"

"fyne.io/fyne/v2"
"fyne.io/fyne/v2/theme"
)

var adwaitaDarkScheme = map[fyne.ThemeColorName]color.Color{
theme.ColorBlue: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @blue_3
theme.ColorBrown: color.RGBA{0x98, 0x6a, 0x44, 0xff}, // Adwaita color name @brown_3
theme.ColorGray: color.RGBA{0x5e, 0x5c, 0x64, 0xff}, // Adwaita color name @dark_2
theme.ColorGreen: color.RGBA{0x26, 0xa2, 0x69, 0xff}, // Adwaita color name @green_5
theme.ColorNameBackground: color.RGBA{0x24, 0x24, 0x24, 0xff}, // Adwaita color name @window_bg_color
theme.ColorNameButton: color.RGBA{0x30, 0x30, 0x30, 0xff}, // Adwaita color name @headerbar_bg_color
theme.ColorNameError: color.RGBA{0xc0, 0x1c, 0x28, 0xff}, // Adwaita color name @error_bg_color
theme.ColorNameForeground: color.RGBA{0xff, 0xff, 0xff, 0xff}, // Adwaita color name @window_fg_color
theme.ColorNameInputBackground: color.RGBA{0x1e, 0x1e, 0x1e, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNameMenuBackground: color.RGBA{0x1e, 0x1e, 0x1e, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNameOverlayBackground: color.RGBA{0x1e, 0x1e, 0x1e, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNamePrimary: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @accent_bg_color
theme.ColorNameSelection: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @accent_bg_color
theme.ColorNameShadow: color.RGBA{0x00, 0x00, 0x00, 0x5b}, // Adwaita color name @shade_color
theme.ColorNameSuccess: color.RGBA{0x26, 0xa2, 0x69, 0xff}, // Adwaita color name @success_bg_color
theme.ColorNameWarning: color.RGBA{0xcd, 0x93, 0x09, 0xff}, // Adwaita color name @warning_bg_color
theme.ColorOrange: color.RGBA{0xff, 0x78, 0x00, 0xff}, // Adwaita color name @orange_3
theme.ColorPurple: color.RGBA{0x91, 0x41, 0xac, 0xff}, // Adwaita color name @purple_3
theme.ColorRed: color.RGBA{0xc0, 0x1c, 0x28, 0xff}, // Adwaita color name @red_4
theme.ColorYellow: color.RGBA{0xf6, 0xd3, 0x2d, 0xff}, // Adwaita color name @yellow_3
}

var adwaitaLightScheme = map[fyne.ThemeColorName]color.Color{
theme.ColorBlue: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @blue_3
theme.ColorBrown: color.RGBA{0x98, 0x6a, 0x44, 0xff}, // Adwaita color name @brown_3
theme.ColorGray: color.RGBA{0x5e, 0x5c, 0x64, 0xff}, // Adwaita color name @dark_2
theme.ColorGreen: color.RGBA{0x2e, 0xc2, 0x7e, 0xff}, // Adwaita color name @green_4
theme.ColorNameBackground: color.RGBA{0xfa, 0xfa, 0xfa, 0xff}, // Adwaita color name @window_bg_color
theme.ColorNameButton: color.RGBA{0xeb, 0xeb, 0xeb, 0xff}, // Adwaita color name @headerbar_bg_color
theme.ColorNameError: color.RGBA{0xe0, 0x1b, 0x24, 0xff}, // Adwaita color name @error_bg_color
theme.ColorNameForeground: color.RGBA{0x00, 0x00, 0x00, 0xcc}, // Adwaita color name @window_fg_color
theme.ColorNameInputBackground: color.RGBA{0xff, 0xff, 0xff, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNameMenuBackground: color.RGBA{0xff, 0xff, 0xff, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNameOverlayBackground: color.RGBA{0xff, 0xff, 0xff, 0xff}, // Adwaita color name @view_bg_color
theme.ColorNamePrimary: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @accent_bg_color
theme.ColorNameSelection: color.RGBA{0x35, 0x84, 0xe4, 0xff}, // Adwaita color name @accent_bg_color
theme.ColorNameShadow: color.RGBA{0x00, 0x00, 0x00, 0x11}, // Adwaita color name @shade_color
theme.ColorNameSuccess: color.RGBA{0x2e, 0xc2, 0x7e, 0xff}, // Adwaita color name @success_bg_color
theme.ColorNameWarning: color.RGBA{0xe5, 0xa5, 0x0a, 0xff}, // Adwaita color name @warning_bg_color
theme.ColorOrange: color.RGBA{0xff, 0x78, 0x00, 0xff}, // Adwaita color name @orange_3
theme.ColorPurple: color.RGBA{0x91, 0x41, 0xac, 0xff}, // Adwaita color name @purple_3
theme.ColorRed: color.RGBA{0xe0, 0x1b, 0x24, 0xff}, // Adwaita color name @red_3
theme.ColorYellow: color.RGBA{0xf6, 0xd3, 0x2d, 0xff}, // Adwaita color name @yellow_3
}
Loading

0 comments on commit b19c2e6

Please sign in to comment.