Skip to content

having trouble with getting started and showing a window #340

Open
@randompersonperson

Description

@randompersonperson

I'm interested in lgi, and started following the overview, but none of these:

window.title = 'I am a window'
window:show_all()
window.title = window.title .. ' made by Lgi'

do anything and i get an error when i try window.has_resize_grip = true or print(window.style.resize_grip_height)

test.lua:

local lgi = require("lgi")

local Gtk = lgi.Gtk
local Gio = lgi.Gio
local GLib = lgi.GLib

local window = Gtk.Window()

window.title = "I am a window"
window:show_all()
window.title = window.title .. " made by Lgi"

window.has_resize_grip = true
print(window.style.resize_grip_height)

output:

~/coding/lgi_test » lua5.1 test.lua                                                                                                                                             mark@coollaptop
lua5.1: /usr/share/lua/5.1/lgi/override/Gtk.lua:87: bad argument #1 to 'format' (string expected, got nil)
stack traceback:
	[C]: in function 'format'
	/usr/share/lua/5.1/lgi/override/Gtk.lua:87: in function </usr/share/lua/5.1/lgi/override/Gtk.lua:83>
	test.lua:14: in main chunk
	[C]: ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions