Skip to content

Commit

Permalink
merge core-update into goal
Browse files Browse the repository at this point in the history
  • Loading branch information
rcoreilly committed Nov 26, 2024
2 parents 2daff74 + 045a506 commit 4919e82
Show file tree
Hide file tree
Showing 18 changed files with 811 additions and 269 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: '1.22'

Expand All @@ -56,10 +56,10 @@ jobs:

- name: Setup Pages
id: pages
uses: actions/configure-pages@v3
uses: actions/configure-pages@v5

- name: Upload artifact
uses: actions/upload-pages-artifact@v1
uses: actions/upload-pages-artifact@v3
with:
path: "static"

Expand All @@ -73,4 +73,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
uses: actions/deploy-pages@v4
6 changes: 3 additions & 3 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: '1.22'

Expand All @@ -25,7 +25,7 @@ jobs:
run: go build -v ./...

- name: Test
run: go test -v ./... -coverprofile cover.out
run: go test -v ./... -coverprofile cover.out -timeout 30s

- name: Update coverage report
uses: ncruces/go-coverage-report@v0
Expand Down
2 changes: 1 addition & 1 deletion canvas/svg.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ func (sv *SVG) Init() {
if e.MouseButton() != events.Left {
return
}
sv.SetFocus()
sv.SetFocusQuiet()
e.SetHandled()
es := sv.EditState()
sob := sv.SelectContainsPoint(e.Pos(), false, true) // not leavesonly, yes exclude existing sels
Expand Down
4 changes: 2 additions & 2 deletions code/spellpanel.go
Original file line number Diff line number Diff line change
Expand Up @@ -259,9 +259,9 @@ func (sv *SpellPanel) CheckNext() {
hr.TimeNow()
tv.Highlights = append(tv.Highlights, hr)
if sv.LastAction == nil {
sv.SetFocusEvent()
sv.SetFocus()
} else {
sv.LastAction.SetFocusEvent()
sv.LastAction.SetFocus()
}
tv.NeedsRender()
}
Expand Down
6 changes: 3 additions & 3 deletions code/symbolspanel.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ func (sv *SymbolsPanel) makeToolbar(p *tree.Plan) {
w.OnChange(func(e events.Event) {
sv.Params().Scope = w.CurrentItem.Value.(SymScopes)
sv.UpdateSymbols()
sv.SearchText().SetFocusEvent()
sv.SearchText().SetFocus()
})
w.SetCurrentValue(sv.Params().Scope) // todo: also update?
})
Expand All @@ -171,7 +171,7 @@ func (sv *SymbolsPanel) makeToolbar(p *tree.Plan) {
// RefreshAction loads symbols for current file and scope
func (sv *SymbolsPanel) RefreshAction() {
sv.UpdateSymbols()
sv.SearchText().SetFocusEvent()
sv.SearchText().SetFocus()
}

func SelectSymbol(cv *Code, ssym syms.Symbol) {
Expand All @@ -189,7 +189,7 @@ func SelectSymbol(cv *Code, ssym syms.Symbol) {
tr := text.NewRegion(ssym.SelectReg.St.Ln, ssym.SelectReg.St.Ch, ssym.SelectReg.Ed.Ln, ssym.SelectReg.Ed.Ch)
tv.Highlights = append(tv.Highlights, tr)
tv.SetCursorTarget(tr.Start)
tv.SetFocusEvent()
tv.SetFocus()
cv.FocusOnTabs()
tv.NeedsLayout()
}
Expand Down
4 changes: 2 additions & 2 deletions code/texteditors.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ func (cv *Code) SetActiveTextEditorIndex(idx int) *TextEditor {
av.Buffer.FileModCheck()
}
cv.SetStatus("")
av.SetFocusEvent()
av.SetFocus()
return av
}

Expand Down Expand Up @@ -192,7 +192,7 @@ func (cv *Code) OpenFileAtRegion(filename core.Filename, tr text.Region) (tv *Te
tv.Highlights = tv.Highlights[:0]
tv.Highlights = append(tv.Highlights, tr)
tv.SetCursorTarget(tr.Start)
tv.SetFocusEvent()
tv.SetFocus()
tv.NeedsLayout()
return tv, true
}
Expand Down
8 changes: 4 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module cogentcore.org/cogent
go 1.22

require (
cogentcore.org/core v0.3.5-0.20241008063015-a9780190b4d3
cogentcore.org/core v0.3.6-0.20241125091405-29e40fa36d9b
github.com/Knetic/govaluate v3.0.0+incompatible
github.com/aandrew-me/tgpt/v2 v2.7.2
github.com/alecthomas/chroma/v2 v2.13.0
Expand All @@ -17,11 +17,11 @@ require (
github.com/emersion/go-smtp v0.21.1
github.com/go-delve/delve v1.22.1
github.com/mattn/go-shellwords v1.0.12
github.com/mitchellh/go-homedir v1.1.0
github.com/robert-nix/ansihtml v1.0.1
github.com/shirou/gopsutil/v3 v3.24.2
github.com/stretchr/testify v1.9.0
github.com/yuin/goldmark v1.7.3
golang.org/x/exp v0.0.0-20240222234643-814bf88cf225
golang.org/x/oauth2 v0.20.0
gonum.org/v1/gonum v0.15.0
)
Expand All @@ -48,7 +48,7 @@ require (
github.com/go-jose/go-jose/v4 v4.0.1 // indirect
github.com/go-ole/go-ole v1.3.0 // indirect
github.com/goki/freetype v1.0.5 // indirect
github.com/gomarkdown/markdown v0.0.0-20240626202925-2eda941fd024 // indirect
github.com/gomarkdown/markdown v0.0.0-20240930133441-72d49d9543d8 // indirect
github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7 // indirect
github.com/gorilla/css v1.0.1 // indirect
github.com/h2non/filetype v1.1.3 // indirect
Expand All @@ -62,7 +62,6 @@ require (
github.com/lufia/plan9stats v0.0.0-20240226150601-1dcf7310316a // indirect
github.com/mattn/go-isatty v0.0.20 // indirect
github.com/mattn/go-runewidth v0.0.15 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
github.com/muesli/termenv v0.15.2 // indirect
github.com/pelletier/go-toml/v2 v2.1.2-0.20240227203013-2b69615b5d55 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
Expand All @@ -78,6 +77,7 @@ require (
github.com/yusufpapurcu/wmi v1.2.4 // indirect
golang.org/x/arch v0.7.0 // indirect
golang.org/x/crypto v0.25.0 // indirect
golang.org/x/exp v0.0.0-20240222234643-814bf88cf225 // indirect
golang.org/x/image v0.18.0 // indirect
golang.org/x/mod v0.19.0 // indirect
golang.org/x/net v0.27.0 // indirect
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
cogentcore.org/core v0.3.5-0.20241008063015-a9780190b4d3 h1:fIazr2orn9A3LSCfedi16RXUrG52y0vwSS5YYDp9B4k=
cogentcore.org/core v0.3.5-0.20241008063015-a9780190b4d3/go.mod h1:HiWp9KXOQmYNaW5wdGpMBEHQTVprdsfBzVmTJ8OPk1A=
cogentcore.org/core v0.3.6-0.20241125091405-29e40fa36d9b h1:kVgx3WPYmCQKY/y5WCgKdVGEYvDgMbPuYH8kUYxr85o=
cogentcore.org/core v0.3.6-0.20241125091405-29e40fa36d9b/go.mod h1:q3OrXihYG2aTE2oG785ad5b6aJ3wzSCXeeD2SSLKWIE=
github.com/Bios-Marcel/wastebasket v0.0.4-0.20240213135800-f26f1ae0a7c4 h1:6lx9xzJAhdjq0LvVfbITeC3IH9Fzvo1aBahyPu2FuG8=
github.com/Bios-Marcel/wastebasket v0.0.4-0.20240213135800-f26f1ae0a7c4/go.mod h1:FChzXi1izqzdPb6BiNZmcZLGyTYiT61iGx9Rxx9GNeI=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
Expand Down Expand Up @@ -89,8 +89,8 @@ github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEe
github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls=
github.com/goki/freetype v1.0.5 h1:yi2lQeUhXnBgSMqYd0vVmPw6RnnfIeTP3N4uvaJXd7A=
github.com/goki/freetype v1.0.5/go.mod h1:wKmKxddbzKmeci9K96Wknn5kjTWLyfC8tKOqAFbEX8E=
github.com/gomarkdown/markdown v0.0.0-20240626202925-2eda941fd024 h1:saBP362Qm7zDdDXqv61kI4rzhmLFq3Z1gx34xpl6cWE=
github.com/gomarkdown/markdown v0.0.0-20240626202925-2eda941fd024/go.mod h1:JDGcbDT52eL4fju3sZ4TeHGsQwhG9nbDV21aMyhwPoA=
github.com/gomarkdown/markdown v0.0.0-20240930133441-72d49d9543d8 h1:4txT5G2kqVAKMjzidIabL/8KqjIK71yj30YOeuxLn10=
github.com/gomarkdown/markdown v0.0.0-20240930133441-72d49d9543d8/go.mod h1:JDGcbDT52eL4fju3sZ4TeHGsQwhG9nbDV21aMyhwPoA=
github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
Expand Down
Loading

0 comments on commit 4919e82

Please sign in to comment.