andlabs / ui

Platform-native GUI library for Go.
Other
8.33k stars 651 forks source link

A question about “ui.NewTab()” #311

Closed Releasel0ck closed 6 years ago

Releasel0ck commented 6 years ago

My code is as follows: tab := ui.NewTab() vb1 := ui.NewVerticalBox() lb := ui.NewLabel("Label") vb1.Append(lb, false) tab.Append("page1", vb1) But when my program is running,page1 is blank!There is no Label control. What is wrong with my code?

andlabs commented 6 years ago

What OS?

Releasel0ck commented 6 years ago

@andlabs Build and run on " Windows 10 X64"

CheatCoder commented 6 years ago

What gcc/g++ compiler are you using?

On my Windows 10 x64, the tabs are working correctly. And can i see go run/build with the -x flag ? Don't forget to remove the "username" from the paths :)

Releasel0ck commented 6 years ago

@andlabs @CheatCoder Thank you for your warm answer!I found the problem.The gcc/g++ I used before is mingw32. When I add a parameter ‘-x’, I have an error "cc1.exe: sorry, unimplemented: 64-bit mode not compiled in".When I corrected this mistake, the tabs are working correctly.

andlabs commented 6 years ago

That's odd; the binary shouldn't even be produced if that was the error... Were you running an older build by mistake?

Releasel0ck commented 6 years ago

I'm sure it's not an old program. I've been using this mingw32.I also feel very odd.

CheatCoder commented 6 years ago

Sorry, I had no internet. But when the problem is solved, we can close the issue now.