#go-nuts

/

      • dsal
        If you have to consider panics, you're back to exception chaos where mystery errors pop up all the time and lead to invisible exit paths.
      • paulohp joined the channel
      • peppi has quit
      • PeterO has quit
      • pietro10
        dsal: then you enter the wonderful world of GUI programming on non-Windows platforms and realize just how much of a pipe dream that is :/
      • GTK+ - you can't intercept internal errors
      • Cocoa - I got yelled at for asking how
      • (though you can)
      • Wessie
        That's more a problem with whatever the GUI is written in :)
      • pietro10
        but I digress
      • Wessie
        it isn't Go, so the panic rules don't apply fully
      • pietro10
        (GTK+ is based on GLib which uses error values in a lot fo places though...)
      • dsal
        In python, "x + 1" can break in countless ways and take your program with it. In go, it just adds one to x
      • pietro10
        (yes, error values, type GError*, must be initailzed to NULL)
      • clutchski has quit
      • dsal: I need to dig up raymond chen's exception handling aritcles sometime
      • sammie has quit
      • would have done it now but didn't feel the diversion was really necessary
      • yamadapc joined the channel
      • assia_t has quit
      • NotVulcan has quit
      • charliewalnut
        this may be off topic, but i'm using vim with an autocmd to run :Fmt on save which works great but makes undo stupid - it puts the cursor at the top of the file and has odd history issues. anyone know a way to make this work better?
      • fss has quit
      • myklgo
        pietro10: What would you write a gui in now with wayland on the horizon? (with go of course)
      • pietro10
        you're confusing GUI with window system
      • or maybe I'm misleading by calling it a GUI instead of a widget toolkit
      • one fo the two
      • kazupon has quit
      • my UI package is a widget toolkit
      • cd1 joined the channel
      • charliewalnut
        http://stackoverflow.com/questions/18532692/gol... has a partial solution but it's not great
      • myklgo
        well, which toolkit will work running on wayland, is that an acceptable question...or rather easiest to implement thatt will run on top of wayland.
      • skriptble joined the channel
      • pietro10
        OH
      • I see what you're asking now
      • sorry
      • I misunderstood what youw ere saying
      • never mind what I said
      • twmb has left the channel
      • AGreyCrane has quit
      • GTK+ can run on Wayland; if you have the weston x client then you can try it with GDK_BACKEND=wayland
      • Qt can also use wayland as a backend but I don't know how
      • myklgo
        qt5
      • neilc has quit
      • pietro10
        no I mean I don't know how to get Qt to use Wayland - if that's a compile time setting, an environment variable, or something else
      • myklgo
        I wanted to write a simple irc with undress windows scrolling on the side.
      • pietro10
        I don't think there are any other otolkits that are yet wayland native, but there's always xwayland
      • Rojtjo has quit
      • bmats has quit
      • myklgo
        undress=undressed
      • pietro10
        "undress windows?"
      • (still don't know what that means)
      • azerus joined the channel
      • myklgo
        no buttons unframed
      • pietro10
        oh
      • myklgo
        like chat bubbles
      • pietro10
        if I understand that correctly, both gtk and qt should provide mechanisms to disable the window decoration
      • wildnux has quit
      • jjmalina has quit
      • tealMage joined the channel
      • wildnux joined the channel
      • cnbuff410 joined the channel
      • or if you mean you want the chat program to look like cell phone chat programs, then that's not an X11'Wayland question, that's a question of programming the proper display view
      • which would be done entirely in the toolkit
      • bmats joined the channel
      • myklgo
        all my ui work has been in html/html5 for years. Javascript /sigh. so really do not know where to start in gui now.
      • FIFOd joined the channel
      • cnbuff410 has quit
      • cespare joined the channel
      • pietro10
        ok
      • cnbuff410 joined the channel
      • myklgo
        before that was all windows but I just wanted to do something for linux.
      • jpoz_ has quit
      • pietro10
        well the first thing to understand is the difference between the window system (X11/Wayland) and the GUI API that you program with, or "widiget toolkit"
      • bmats has quit
      • yamadapc has quit
      • bmats joined the channel
      • you typically don't need to talk to the window system directly
      • those toolkit librarlies like GTK+ and Qt do that for you
      • myklgo
        Some will support wayland sooner and some later. Just thought sooner might be better.
      • nelish has quit
      • pietro10: thanks.
      • pietro10
        now when you make UIs in HTML what did you use
      • AGreyCrane joined the channel
      • myklgo
        I cannot even use JQuery, I write everything myself.
      • balboah joined the channel
      • Terrible quirk in my personality
      • paulohp has quit
      • xmm2 has quit
      • In house anyway.
      • wildnux has quit
      • virtuallynathan_ has quit
      • paulohp joined the channel
      • pietro10
        heh
      • atotto joined the channel
      • cnbuff410 has quit
      • wildnux joined the channel
      • bmats has quit
      • ggp has quit
      • well with native GUI toolkits you still lay out controls (you don't lay out HTML stuff like text or images outside of dedicated controls though) and respond to events in a traditional way
      • myklgo
        Business app, accept for the login page everything is javascript
      • bradbeam joined the channel
      • pietro10
        beyond that I can suggest
      • nanoyak has quit
      • ggp joined the channel
      • myklgo
        Actually I do, I created a button factory that utilizes the id to pass the action back to the server.
      • kenCodes is now known as zz_kenCodes
      • pietro10
      • for GTK+
      • https://developer.gnome.org/gtk3/3.4/gtk-gettin... a smaller version that also talks about custom drawing
      • djbkd has quit
      • ClarusCogitatio has quit
      • see if you can follow along with the concepts from HTML tto give hints
      • myklgo
        except=accept
      • ibk has quit
      • xeger has quit
      • st33med
        When I tried making GUIs years back, I found it a weird experience. It felt hacked in to the language of Python or C
      • Example, you check for a button click through a string
      • Passed from a function
      • atotto has quit
      • wildnux has quit
      • ClarusCogitatio joined the channel
      • pietro10
        I'm going to guess you were using Tk for that, which because it's based on Tcl, works like that
      • wildnux joined the channel
      • these don't work like that
      • jpoz joined the channel
      • jayd3e has quit
      • st33med
        GTK+, even
      • pnielsen has quit
      • jxf has quit
      • djbkd joined the channel
      • alemedeiros has quit
      • ClarusCogitatio has quit
      • myklgo
        pietro10: Thanks for your patience. I have had a bad flu for the last week and my brain has been seriously impaired. Or it lets me realize how impaired I normally am.
      • ClarusCogitatio joined the channel
      • pietro10
        heh
      • pnielsen joined the channel
      • no problem
      • wildnux has quit
      • I actually don't know much about HTML app programming so that's about as much help as I can give though :/ sorry
      • wildnux joined the channel
      • P0w3r3d has quit
      • charliewalnut
        if folks reading the log are curious about my previous question, appears the best answer i can find is the go-vim plugin. will try that out
      • josh-k has quit
      • xeger joined the channel
      • Wessie
        I don't have such issues charliewalnut, I'm using gocode with goimports
      • schleppy
        I have a channel (reply) in a struct that I am passing in another channel. The idea is, you send the reply channel for the goroutine to send results. If I leave the reply channel unbuffered, as soon as I get two simultaneous requests my app hangs indefinitely. If I used a buffered channel of size 2 I can sent any number of simultaneous requests (have tried with 100+) and everything is just fine. What on Earth could I be missing?
      • mreedell joined the channel
      • charliewalnut
        Wessie: meaning you can make a (badly formatted) edit, save, have it autoformat, then hit 'u' a few times and not have the cursor jump to the top? do you know how this works?