Search found 33 matches

by YounYokel
Sun Feb 02, 2020 11:07 am
Forum: Support and Development
Topic: "Not enough space" error when printing a string
Replies: 12
Views: 4452

Re: "Not enough space" error when printing a string

I insist that you head over to Wikipedia and study carefully the article about UTF-8 encoding. Weird that other function does work which inserts a string in given position works which is almost the same. I'm pretty sure inserting to an index that would be between two bytes of a multibyte character ...
by YounYokel
Sun Feb 02, 2020 6:44 am
Forum: Support and Development
Topic: "Not enough space" error when printing a string
Replies: 12
Views: 4452

Re: "Not enough space" error when printing a string

raidho36 wrote:
Sun Feb 02, 2020 12:26 am
I insist that you head over to Wikipedia and study carefully the article about UTF-8 encoding.
Weird that other function does work which inserts a string in given position works which is almost the same.
by YounYokel
Sat Feb 01, 2020 8:01 pm
Forum: Support and Development
Topic: "Not enough space" error when printing a string
Replies: 12
Views: 4452

Re: "Not enough space" error when printing a string

Guys why doesn't this work? Checking the reference manual, i didn't see any utf8.sub function there. ( http://www.lua.org/manual/5.3/manual.html#6.5 - löve implements this itself fully as its own utf-8 lib) Also, shouldn't step be math.floor-ed? at some point? not sure if it's a good idea to pass i...
by YounYokel
Sat Feb 01, 2020 6:12 pm
Forum: Support and Development
Topic: "Not enough space" error when printing a string
Replies: 12
Views: 4452

Re: "Not enough space" error when printing a string

Guys why doesn't this work? str = [[Popiš památku je název soutěže pro nové i zkušené wikipedisty, která se koná od 15. ledna do 15. února 2020, tedy jeden měsíc. Aktuální, již třetí ročník soutěže pořádá opět spolek Wikimedia Česká republika. Partnerem soutěže je portál PROPAMÁTKY.]] local utf8 = r...
by YounYokel
Sat Feb 01, 2020 8:58 am
Forum: Support and Development
Topic: Can love.filesystem.read skip custom linebreaks?
Replies: 12
Views: 3789

Re: Can love.filesystem.read skip custom linebreaks?

Oh OK, so what you want is probably this: love.filesystem.read():gsub('\r?\n', ''):gsub('\\n', '\n') Applied to your example: s = [[Hello World. This is a test file which contains some text.\n Thanks, bye! ]] print((s:gsub('\r?\n', ''):gsub('\\n', '\n'))) --[[ prints: Hello World.This is a test fil...
by YounYokel
Fri Jan 31, 2020 6:06 pm
Forum: Support and Development
Topic: Can love.filesystem.read skip custom linebreaks?
Replies: 12
Views: 3789

Re: Can love.filesystem.read skip custom linebreaks?

Not gonna edit my previous post, but instead i'll post what i *actually* wanted to: love.filesystem.read():gsub('\r', [[\r]]):gsub('\n', [[\n]]) Basically, i assumed that OP wanted to turn the functional versions into string representations of the escape sequences. (double sqr brackets don't parse ...
by YounYokel
Thu Jan 30, 2020 10:48 am
Forum: Support and Development
Topic: Can love.filesystem.read skip custom linebreaks?
Replies: 12
Views: 3789

Can love.filesystem.read skip custom linebreaks?

Hey, love.filesystem.read() returns a string with linebreaks added in a file by user with Enter button and with \n , but it makes harder to read and modify the original text. I'd like to know is there a way to ignore Enter keys but still read the \n signs? That would be useful. :awesome: Thanks.
by YounYokel
Thu Jan 30, 2020 10:41 am
Forum: Support and Development
Topic: How do I install on Linux system?
Replies: 5
Views: 1427

Re: How do I install on Linux system?

What's your graphics card? Do you have GL drivers for it? Does glxgears work for you? Also, the output of: 'glxinfo | grep string' (without the quotes) would be useful. Both are in package mesa-utils. Edit: swrast is the software rasterizer (software OpenGL). That sounds like you don't have drivers...
by YounYokel
Tue Jan 28, 2020 2:00 pm
Forum: Support and Development
Topic: How do I install on Linux system?
Replies: 5
Views: 1427

Re: How do I install on Linux system?

And... it doesn't run libGL error: No matching fbConfigs or visuals found libGL error: failed to load driver: swrast X Error of failed request: GLXBadContext Major opcode of failed request: 154 (GLX) Minor opcode of failed request: 6 (X_GLXIsDirect) Serial number of failed request: 107 Current seria...
by YounYokel
Tue Jan 28, 2020 1:54 pm
Forum: Support and Development
Topic: How do I install on Linux system?
Replies: 5
Views: 1427

Re: How do I install on Linux system?

grump wrote:
Tue Jan 28, 2020 1:45 pm
You did not install love yet, you just added the repository to apt. Try

Code: Select all

sudo apt install love
Oh, that's funny because it was my first thought to do that. Then I tried this I didn't recognised the packages and thought that it was some kind of system application. Silly me))

Thank you! =3