On 2026-08-12, Lawrence D’Oliveiro <[email protected]> wrote:
> Here’s an example snippet from my limited dabbling with GTK4 so far:
>
>     ui = \
>         (
>             "<?xml version='1.0' encoding='utf-8'?>\n"
>             "<interface>\n"
>             "    <requires lib='gtk' version='4.0'/>\n"
>             "    <object class='GtkWindow' id='main'>\n"
>             "        <child>\n"
>             "            <object class='GtkGLArea' id='draw'/>\n"
>             "        </child>\n"
>             "    </object>\n"
>             "</interface>\n"
>         )

Just to say that would obviously be a lot easier and cleaner like this:

ui = '''
    <?xml version='1.0' encoding='utf-8'?>
    <interface>
        <requires lib='gtk' version='4.0'/>
        <object class='GtkWindow' id='main'>
            <child>
                <object class='GtkGLArea' id='draw'/>
            </child>
        </object>
    </interface>
'''
-- 
https://mail.python.org/mailman3//lists/python-list.python.org

Reply via email to