سؤال

I'd like to retrieve a string from the user using awesome. I'll use this string to dynamically create a new tag. I just need some function that I can call that will take input from the keyboard and return the text that was typed in.

هل كانت مفيدة؟

المحلول

Something like this should help you get started:

awful.prompt.run({ prompt = "Magic: " },
    mypromptbox[mouse.screen].widget, function(text)
        naughty.notify({ text = "you entered: " .. text })
    end))
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top