lxn / walk Goto Github PK
View Code? Open in Web Editor NEWA Windows GUI toolkit for the Go Programming Language
License: Other
A Windows GUI toolkit for the Go Programming Language
License: Other
Building is OK, but failed to run.
Any progress on windows_amd64?
i really like this project example,but i not found treeview example.
Well, walk is a great work!
It's powerful though quite simple to use!
I want to know Is there "Balloon ToolTip" for walk.NotifyIcon; or how to add some(i'm not familiar with the Win32 API)?
go run notifyicon.go
2013/07/26 16:39:19 TTM_ADDTOOL failed
Stack:
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/error.go:79 (0x42ba2f)
com/lxn/walk.newErr: return &Error{message: message, stack: debug.Stack()}
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/error.go:83 (0x42bb22)
com/lxn/walk.newError: return processError(newErr(message))
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/tooltip.go:115 (0x43ea31)
com/lxn/walk.(*ToolTip).AddTool: return newError("TTM_ADDTOOL failed")
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/widget.go:110 (0x44229d)
com/lxn/walk.(*WidgetBase).init: if err := globalToolTip.AddTool(wb); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/window.go:386 (0x4447e0)
com/lxn/walk.InitWindow: if err := wb.init(widget); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/widget.go:86 (0x442057)
com/lxn/walk.InitWidget: if err := InitWindow(widget, parent, className, style|win.WS_CHILD, exStyle); err != ni
l {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/composite.go:32 (0x428b8e)
com/lxn/walk.newCompositeWithStyle: win.WS_EX_CONTROLPARENT); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/composite.go:40 (0x428cdb)
com/lxn/walk.NewComposite: return newCompositeWithStyle(parent, 0)
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/form.go:81 (0x42ce66)
com/lxn/walk.(*FormBase).init: if fb.clientComposite, err = NewComposite(form); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/window.go:402 (0x444924)
com/lxn/walk.InitWindow: if err := fb.init(form); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/mainwindow.go:37 (0x4302cc)
com/lxn/walk.NewMainWindow: win.WS_EX_CONTROLPARENT); err != nil {
d:/Users/Cyrus/gofiles/src/github.com/lxn/walk/examples/notifyicon/notifyicon.go:18 (0x40102a)
main: mw, err := walk.NewMainWindow()
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist417694871/go/src/pkg/runtime/proc.c:182 (0x4148e9)
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist417694871/go/src/pkg/runtime/proc.c:1223 (0x416a40)
exit status 1
first, i am sorry for my poor english
in mainwindow.go file, if i want to do some frameless window, i will use setAndClearStyleBits func, but it is private, does author will public this func, or there is some method for this that i do not found.
I've tried combobox.KeyDown().Attach(fun) and combobox.BaseWidget().KeyDown().Attach(fun), but neither would work. So what's wrong?
Is there any pans to include webkit or blink for web based desktop applications or this already exists ?
In tip, unsafe.Sizeof has been changed to return uintptr. This causes a variety of issues during the build of walk:
bitmap.go:32: cannot use 84 (type uintptr) as type int in function argument
bitmap.go:65: cannot use 84 (type uintptr) as type int in function argument
document.go:241: cannot use 20 (type uintptr) as type int in assignment
printerinfo.go:213: invalid operation: 8 + (driverLen + printerLen + portLen) * 2 (mismatched types uintptr and int)
printerinfo.go:288: invalid operation: index * 2 (mismatched types int and uintptr)
I can try to send a patch if you like.
It seems that there's no way to edit the item in a TableView, isn't it?
Would this feature be supported?
the tool ‘ui2walk’ can not generate *.go file with *.ui file and the content of the .ui as follow:
I know walk.NewIconFromResource(res string),
but I just want use IDI_APPLICATION predefined icon with NotifyIcon
Using the Qt4 Designer on Linux, I naively created a small user interface consisting of a MainWindow and a push button. The MainWindow automatically contains a Composite
named centralwidget. Inside this composite is a push button:
When run, the contents of the application window seems to have an offset, and it is cut somewhere near the middle of the window:
The result is the same for Windows XP 32-bit, and Wine on Linux.
If I insert the lines
w.ui.centralwidget.SetX(0)
w.ui.centralwidget.SetY(0)
w.ui.centralwidget.SetClientSize(walk.Size{800,600})
into example_ui.go
after the call w.ui.centralwidget.SetName("centralwidget")
, the application window looks right.
It appears to be something wrong with the placement of the centralwidget composite.
Though, even then, if I modify the window's size using the mouse, the push button immediately
snaps back into the old position in the middle of the screen, as shown in the second screenshot.
Is there something the ui2walk tool could do about it? Or, am i missing something, like embedding
layout elements in a certain way to get to the expected behaviour?
The example.ui file and a main.go is available at http://wmipf.de/walk-exampleui/exampleui.zip.
Thanks, Michael
.
Moving a .exe file to a directory other than the one it was compiled in results in no execution. I'm using go version 1.0.3 on an amd64 machine running Vista Enterprise (yeah I know but its a box at work). If I compile the help file sources like this,
cd %GOPATH%\src\screamo
dir
screamo.go screamo.exe.manifest
go build screamo
dir
screamo.go screamo.exe.manifest screamo.exe
Running the executable (cmd line or double click) gives the familiar two panel window and bottom button.
However if I drag the executable or the executable and the manifest file to the desktop, double clicking results in a command window popping up and closing - similar to compiling and running w/o the manifest file.
Inside the walk code, WidgetLists are iterated over by accessing the items slice directly so that you can range over them. It would be nice if you could just use range over the WidgetList itself, since currently you have to go through a container's children the "hard" way.
i am use *.ui create TableView,but i not found SetCloums,so,don't change Cloums?how can change it?
When running any of the examples, I get:
panic: syscall.LoadLibrary("comctl32.dll") failed: %1 is not a valid Win32 application.
I built walk using 6g version weekly.2011-10-18 10125 from inside MSYS (MinGW) and gomake. Is this an issue due to using the 64-bit compiler instead of 32-bit?
Does walk fo go only work well in Windows?My OS is Mac, I can't install walk and the errors is showed behind.
$ go get github.com/lxn/walk
github.com/lxn/go-winapi
Documents/Go/mypkg/src/github.com/lxn/go-winapi/advapi32.go:80: too many arguments in call to syscall.Syscall
Documents/Go/mypkg/src/github.com/lxn/go-winapi/advapi32.go:93: too many arguments in call to syscall.Syscall6
Documents/Go/mypkg/src/github.com/lxn/go-winapi/advapi32.go:105: too many arguments in call to syscall.Syscall6
Documents/Go/mypkg/src/github.com/lxn/go-winapi/advapi32.go:112: undefined: syscall.Syscall9
Documents/Go/mypkg/src/github.com/lxn/go-winapi/advapi32.go:131: too many arguments in call to syscall.Syscall6
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:206: too many arguments in call to syscall.Syscall
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:215: too many arguments in call to syscall.Syscall
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:227: too many arguments in call to syscall.Syscall6
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:235: too many arguments in call to syscall.Syscall
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:245: too many arguments in call to syscall.Syscall
Documents/Go/mypkg/src/github.com/lxn/go-winapi/comctl32.go:245: too many errors
the current TreeView item can only be selected by left mouse click, what's wrong?
It is a little pity that there is always a CONSOLE window on the screen .How Can I remove it ?
When I build it by "-ldflags -Hwindowsgui",It returns "unknown flag -Hwindowsgui"
AS FOLLOWING:
E:\go\workspace\src\DQPS>go build -ldflags -Hwindowsgui
DQPS
E:\GO\GO\pkg\tool\windows_386\8l.exe: unknown flag -Hwindowsgui
how can i pick a folder location?
If the locale's "No. of digits after decimal" is set to 0 (Region & Language > Additional Settings), all of the example binaries (and presumably all other walk binaries) panic on startup:
panic: runtime error: index out of range
goroutine 1 [running]:
github.com/lxn/walk.init()
D:/lang/gopath/src/github.com/lxn/walk/util.go:47 +0x18f
The problem goes away if the setting is changed or by monkeypatching values for decimalSetB
etc. in util.go.
This is on en_GB; I'm not sure if this is the default for this or any locale, but I can't remember setting it myself (although that's often the case with mysteriously broken things on Windows).
why must has *.exe.manifest?
Size: Size{800, 600}, Can I use percentages do?
You can give me your mail do? Always here to ask questions is not good.
splitter.go:23: undefined:GetSysColor
It appears to me that the Text item of a CheckBox gets truncated, i.e. the
last few characters won't be displayed, as can be seen from the screenshot
made on Windows XP:
The source of the program can be found at http://play.golang.org/p/7dHkImdPLF.
I had a look at walk/checkbox.go:/MinSizeHint, where a minimum width is calculated
as the sum of the width of the checkbox icon and the width of the displayed text.
I wondered whether there should be a compensation for the little space between
the icon and the text, provided this compensation isn't already accounted for by
the GetSystemMetrics call. My naive approach to fix the problem was to add the extra
width of an 'n' to the textSize:
--- a/checkbox.go
+++ b/checkbox.go
@@ -33,7 +33,7 @@ func (*CheckBox) LayoutFlags() LayoutFlags {
func (cb *CheckBox) MinSizeHint() Size {
defaultSize := cb.dialogBaseUnitsToPixels(Size{50, 10})
- textSize := cb.calculateTextSize()
+ textSize := cb.calculateTextSizeImpl("n"+widgetText(cb.hWnd))
// FIXME: Use GetThemePartSize instead of GetSystemMetrics?
w := textSize.Width + int(GetSystemMetrics(SM_CXMENUCHECK))
This change seems to fix the issue for me, at least on Windows XP (I don't have access
to newer versions of Windows).
Michael
PS: The additional HSpacer (still commented out) in the example program
is necessary to avoid the text of the first checkbox being clipped.
I see the FileDialog, but it works only for plain files.
So how to select folder with WALK?
Thanks
Because the size of uint and int aren't specified in the go-spec (they could be either 32 or 64 bit), and the size of int is specified for the Windows API to be 32 bit, I would suggest using int32 and uint32 for the Windows structures.
In Go 1 (and at tip right now), it is illegal to compare function pointers against one another. Only comparisons against nil are allowed. In cancelevent.go (and the others!), Detach no longer compiles:
func (e *CancelEvent) Detach(handler CancelEventHandler) {
for i, h := range e.handlers {
if h == handler {
e.handlers = append(e.handlers[:i], e.handlers[i+1:]...)
return
}
}
}
You can no longer do the h == handler
comparison.
Proposal for a changed interface: return a handle which is equal to the index of the function. Make Detach take (index int) and do e.handlers[index] = nil
. In Publish, call the function only if non-nil.
Ideally, there would be a common signature for the different kinds of handler functions and only one Event type with different instances ...
hi lxn, i found example
imageviewer
logview
have error:
logview git:(master) ✗ go build
logview git:(master) ✗ ./logview
panic: App().Settings() must not be nil
Stack:
E:/code/go/src/github.com/lxn/walk/error.go:77 (0x43ec9f)
com/lxn/walk.newErr: return &Error{message: message, stack: debug.Stack()}
E:/code/go/src/github.com/lxn/walk/error.go:81 (0x43ed92)
com/lxn/walk.newError: return processError(newErr(message))
E:/code/go/src/github.com/lxn/walk/widget.go:1382 (0x457005)
com/lxn/walk.(*WidgetBase).getState: return "", newError("App().Settings() must not be nil")
E:/code/go/src/github.com/lxn/walk/toplevelwindow.go:235 (0x44f61b)
com/lxn/walk.(*TopLevelWindow).RestoreState: state, err := tlw.getState()
E:/code/go/src/github.com/lxn/walk/toplevelwindow.go:184 (0x44f108)
com/lxn/walk.(*TopLevelWindow).Show: tlw.RestoreState()
E:/code/go/src/github.com/lxn/walk/examples/logview/logviewapp.go:33 (0x4017cb)
main: myWindow.Show()
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist357622851/go/src/pkg/runtime/proc.c:182 (0x415299)
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist357622851/go/src/pkg/runtime/proc.c:1223 (0x4173f0)
While using a ListModel, the PublishItemsReset method would "tell" the ComboBox to reload the data, but a slice of structs can't do this.
When using WALK in a declarative style, "slice of structs" is much more convenient to be used as data binding sources, but the lack of model reloading mechanism makes it a little less convenient.
When I use go build with the example , it just produce a executable file, when I run it, nothing happened, no error infos and no window display.
forgive my pool english .
what's wrong? I install the latest walk package and go 1.0.3
Under Windows 7 and Aero interface.
When mouse is over these buttons, they start to flicker multiple times per second: selected - unselected - selected - etc.
It happens only if aero is enabled.
..\github.com\lxn\walk\tableview.go:385: undefined: LVSICF_NOSCROLL
I am very confused with using tabpage and always failed.
Is there any examples?
When I "go get github.com/lxn/walk",So many errors prevented me from building the package as following:
"
E:\go\workspace\src\github.com\lxn\walk\clipboard.go:101: undefined: syscall.UT
16FromString
E:\go\workspace\src\github.com\lxn\walk\inifilesettings.go:141: undefined: bufi
.NewScanner
E:\go\workspace\src\github.com\lxn\walk\numberedit.go:148: undefined: syscall.U
F16FromString
E:\go\workspace\src\github.com\lxn\walk\numberedit.go:171: undefined: syscall.U
F16FromString
E:\go\workspace\src\github.com\lxn\walk\statusbar.go:136: method sbi.updateIcon
is not an expression, must be called
E:\go\workspace\src\github.com\lxn\walk\statusbar.go:153: method sbi.updateText
is not an expression, must be called
E:\go\workspace\src\github.com\lxn\walk\statusbar.go:170: method sbi.updateTool
ipText is not an expression, must be called
E:\go\workspace\src\github.com\lxn\walk\statusbar.go:256: undefined: syscall.UT
16PtrFromString
E:\go\workspace\src\github.com\lxn\walk\statusbar.go:273: undefined: syscall.UT
16PtrFromString
"
I do think it is an impossible accident which really happend.Would u please tell me WHY?
Is there any chance to make a window full screen?
Thanks
Now TopLevelWindow has ToolBar support but not StatusBar, Would there be some StatusBar support?
google found this:
https://groups.google.com/forum/#!msg/golang-nuts/ELeedbCkqLI/u0tr5P47ChsJ
question is step 4: how to link complied object file using 'go command'? is it possible?
The goplay failed with this output when fed with the content of examples/drawing.go
. But when doing: go run drawing.go
, it's ok.
The other program i write using the ui2walk.exe generated ui files runs into this kind of panic again.
It seems there's something wrong with walk.InitWidget
, is't right? How to fix it?
panic: TTM_ADDTOOL failed
Stack:
E:/repos/libs/gopkgs/src/github.com/lxn/walk/error.go:77 (0x4219b9)
com/lxn/walk.newErr: return &Error{message: message, stack: debug.Stack()}
E:/repos/libs/gopkgs/src/github.com/lxn/walk/error.go:81 (0x421a50)
com/lxn/walk.newError: return processError(newErr(message))
E:/repos/libs/gopkgs/src/github.com/lxn/walk/tooltip.go:113 (0x42b716)
com/lxn/walk.(*ToolTip).AddTool: return newError("TTM_ADDTOOL failed")
E:/repos/libs/gopkgs/src/github.com/lxn/walk/widget.go:423 (0x4307fe)
com/lxn/walk.InitWidget: if err := globalToolTip.AddTool(widget); err != nil {
E:/repos/libs/gopkgs/src/github.com/lxn/walk/mainwindow.go:30 (0x423b06)
com/lxn/walk.NewMainWindow: WS_EX_CONTROLPARENT); err != nil {
C:/Documents and Settings/Administrator/Local Settings/Temp/compile11.go:82 (0x4017d1)
main: mainWnd, _ := walk.NewMainWindow()
C:/Go/src/pkg/runtime/proc.c:244 (0x40f12a)
main: main·main();
C:/Go/src/pkg/runtime/proc.c:271 (0x40f1c2)
goexit: runtime·goexit(void)
In the old treeview implementation, i found it's easy to make a expandable treeview item,
But now how can i do that?
I get the following during installation
go get github.com/lxn/walk
# github.com/lxn/walk
C:\run\go\src\pkg\github.com\lxn\walk\clipboard.go:101: undefined: syscall.UTF16
FromString
C:\run\go\src\pkg\github.com\lxn\walk\inifilesettings.go:141: undefined: bufio.N
ewScanner
C:\run\go\src\pkg\github.com\lxn\walk\numberedit.go:148: undefined: syscall.UTF1
6FromString
C:\run\go\src\pkg\github.com\lxn\walk\numberedit.go:171: undefined: syscall.UTF1
6FromString
C:\run\go\src\pkg\github.com\lxn\walk\statusbar.go:136: method sbi.updateIcon is
not an expression, must be called
C:\run\go\src\pkg\github.com\lxn\walk\statusbar.go:153: method sbi.updateText is
not an expression, must be called
C:\run\go\src\pkg\github.com\lxn\walk\statusbar.go:170: method sbi.updateToolTip
Text is not an expression, must be called
C:\run\go\src\pkg\github.com\lxn\walk\statusbar.go:256: undefined: syscall.UTF16
PtrFromString
C:\run\go\src\pkg\github.com\lxn\walk\statusbar.go:273: undefined: syscall.UTF16
PtrFromString
C:\Users\sony>go get github.com/lxn/walk
C:\Go\src\pkg\github.com\lxn\walk\listbox.go:39: undefined: LBS_STANDARD
C:\Go\src\pkg\github.com\lxn\walk\listbox.go:82: undefined: LB_ERRSPACE
C:\Go\src\pkg\github.com\lxn\walk\listbox.go:82: undefined: LB_ERR
C:\Go\src\pkg\github.com\lxn\walk\listbox.go:232: undefined: LB_ERR
The DataBinder
has a Submit
method to extract data from the GUI to the underlying data source. But it seems that the data source is only loaded once at the very first binding initialization period and no way to load the data source anymore, isn't it?
Since WALK supports the Property mechanism, would it be fantastic to have double way bindings?
$ gomake
make -C pkg/walk/winapi clean
make[1]: Entering directory `/d/Downloads/walk/src/pkg/walk/winapi'
rm -rf *.o *.a *.[568vq] [568vq].out *.so _obj _test _testmain.go *.exe _cgo* *.
cgo[12].* test.out build.out
make[1]: Leaving directory `/d/Downloads/walk/src/pkg/walk/winapi'
make -C pkg/walk clean
make[1]: Entering directory `/d/Downloads/walk/src/pkg/walk'
rm -rf *.o *.a *.[568vq] [568vq].out *.so _obj _test _testmain.go *.exe _cgo* *.
cgo[12].* test.out build.out
make[1]: Leaving directory `/d/Downloads/walk/src/pkg/walk'
make -C cmd/tools/ui2walk clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/tools/ui2walk'
rm -rf *.o *.a *.[568vq] [568vq].out ui2walk.exe _test _testmain.go test.out bui
ld.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/tools/ui2walk'
make -C cmd/examples/drawing clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/drawing'
rm -rf *.o *.a *.[568vq] [568vq].out drawing.exe _test _testmain.go test.out bui
ld.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/drawing'
make -C cmd/examples/filebrowser clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/filebrowser'
rm -rf *.o *.a *.[568vq] [568vq].out filebrowser.exe _test _testmain.go test.out
build.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/filebrowser'
make -C cmd/examples/imageviewer clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/imageviewer'
rm -rf *.o *.a *.[568vq] [568vq].out imageviewer.exe _test _testmain.go test.out
build.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/imageviewer'
make -C cmd/examples/notifyicon clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/notifyicon'
rm -rf *.o *.a *.[568vq] [568vq].out notifyicon.exe _test _testmain.go test.out
build.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/notifyicon'
make -C cmd/examples/printing clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/printing'
rm -rf *.o *.a *.[568vq] [568vq].out printing.exe _test _testmain.go test.out bu
ild.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/printing'
make -C cmd/examples/tableview clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/tableview'
rm -rf *.o *.a *.[568vq] [568vq].out tableview.exe _test _testmain.go test.out b
uild.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/tableview'
make -C cmd/examples/webbrowser clean
make[1]: Entering directory `/d/Downloads/walk/src/cmd/examples/webbrowser'
rm -rf *.o *.a *.[568vq] [568vq].out webbrowser.exe _test _testmain.go test.out
build.out
make[1]: Leaving directory `/d/Downloads/walk/src/cmd/examples/webbrowser'
make -C pkg/walk/winapi install
make[1]: Entering directory `/d/Downloads/walk/src/pkg/walk/winapi'
8g -o _go_.8 advapi32.go combobox.go comctl32.go comdlg32.go datetimepicker.go
edit.go gdi32.go gdiplus.go kernel32.go listview.go menu.go ole32.go oleaut32.go
shdocvw.go shell32.go tab.go toolbar.go tooltip.go treeview.go updown.go user32
.go uxtheme.go winapi.go winspool.go
winapi.go:56: undefined: syscall.Handle
make[1]: *** [_go_.8] Error 1
make[1]: Leaving directory `/d/Downloads/walk/src/pkg/walk/winapi'
make: *** [all] Error 2
I want to simulate some mouse events like winAPI mouse_event() or keybd_event()
but,i haven't find it in walk pkg
so,i post this issue for answer
I'm new to Go, so I'm not too sure how this issue is happening.
When attempting to run the Webview example, I get a crash after the HTML page loads:
Faulting application name: walk-web.exe, version: 0.0.0.0, time stamp: 0x4f750a0a
Faulting module name: walk-web.exe, version: 0.0.0.0, time stamp: 0x4f750a0a
Exception code: 0x80000003
Fault offset: 0x00000000000197b7
Faulting process id: 0x16e4
Faulting application start time: 0x01cd0e159a0ba747
Faulting application path: C:\Users\dmuso\Documents\Code\Go\1\examples\walk-web\walk-web.exe
Faulting module path: C:\Users\dmuso\Documents\Code\Go\1\examples\walk-web\walk-web.exe
Report Id: d9c0a249-7a08-11e1-9bef-180373d18cf0
There isn't any stack trace or debugging information here, and I'm not too sure how I can get that out. I'm happy to do some more investigation if it helps.
I can successfully build and use the imageviewer example, so my install of Go and Walk seem to be working properly.
My environment is:
Windows 7 x64, Go1
If I comment out loading a URL in the code, the window and webview control will load and not crash, so this only seems to be triggered when loading a website within the webview control.
It will also crash if after the window loads without a URL, I type one in the text field and hit enter.
I tried varies examples on varies versions of Windows and ReactOS.
XP: all works perfectly.
7: crashes on certain commands.
ReactOS: file browser worked but everything else crashed.
These were all built from source. I tried using the apps built with 7 on XP and ReactOS and all gave an error.
Attempting to use the declarative interface to Create()
a LineEdit widget causes an error with the message "EM_SETCUEBANNER failed". As the title may suggest, it's still possible to initialize a LineEdit widget using the standard imperative interface.
C:/Go/src/pkg/github.com/lxn/walk/error.go:77 (0x42ec1f)
com/lxn/walk.newErr: return &Error{message: message, stack: debug.Stack()}
C:/Go/src/pkg/github.com/lxn/walk/error.go:81 (0x42ecf3)
com/lxn/walk.newError: return processError(newErr(message))
C:/Go/src/pkg/github.com/lxn/walk/lineedit.go:83 (0x4339f8)
com/lxn/walk.(*LineEdit).SetCueBanner: return newError("EM_SETCUEBANNER failed")
C:/Go/src/pkg/github.com/lxn/walk/declarative/lineedit.go:48 (0x44a680)
com/lxn/walk/declarative._func_010: if err := w.SetCueBanner(le.CueBanner); err != nil {
C:/Go/src/pkg/github.com/lxn/walk/declarative/util.go:104 (0x44a39c)
com/lxn/walk/declarative.InitWidget: if err := customInit(); err != nil {
C:/Go/src/pkg/github.com/lxn/walk/declarative/lineedit.go:69 (0x4495a4)
com/lxn/walk/declarative.LineEdit.Create: })
D:/Development/go/gowalk-test/linetest.go:21 (0x401297)
main: if err := (dec.LineEdit{AssignTo: &le, Text: "Woot"}).Create(mw); nil != err {
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist767862039/go/src/pkg/runtime/proc.c:244 (0x40e03b)
C:/Users/ADMINI~1/AppData/Local/Temp/2/bindist767862039/go/src/pkg/runtime/proc.c:271 (0x40e0e4)
Compiled and run on Windows 8 64-bit Consumer Preview (build 8400).
package main
import (
"fmt"
"github.com/lxn/walk"
dec "github.com/lxn/walk/declarative"
"os"
)
func ErrorAndExit(err error) {
fmt.Fprintln(os.Stderr, err.Error())
os.Exit(1)
}
func main() {
var mw *walk.MainWindow
if err := (dec.MainWindow{AssignTo: &mw, Title: "LineEdit Test", Layout: dec.VBox{}}.Create()); nil != err {
ErrorAndExit(err)
}
var le *walk.LineEdit
if err := (dec.LineEdit{AssignTo: &le, Text: "Woot"}).Create(mw); nil != err {
ErrorAndExit(err)
}
mw.Children().Add(le)
mw.Run()
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.