Re: DlangUI 0.9.0: Console backend added
p.p.s. yep, VT-100 had only 4 functional keys, so we still enjoying having 'em encoded separately from the others.
Re: DlangUI 0.9.0: Console backend added
On Wednesday, 14 September 2016 at 05:58:51 UTC, Vadim Lopatin wrote: Thank you! Now dlangui terminal mode supports only 16 colors. Some refactoring is required to support RGB colors. in my editor i'm simply using rgb in [0..255] range, and mapping that to what terminal has. yet it is probably not the best way to make something nice looking when only 16 colors are available. heh, i should try and see how it will look like! ;-) On Wednesday, 14 September 2016 at 06:06:51 UTC, Vadim Lopatin wrote: at least in Gnome terminal. maybe gnome terminal took those keys for it's own needs -- like tab switching or something. in xterm, those are usual CSI-with-modifier codes: \e[1;, where is 6 for ctrl+shift, and is A/B/C/D for Up/Down/Right/Left respectively. it is better to check everything in xterm -- this is still the most used terminal emulator out there. just switch it to send for alt-key instead of setting high bit. ;-)
Re: DlangUI 0.9.0: Console backend added
On Wednesday, 14 September 2016 at 13:04:40 UTC, ketmar wrote: On Wednesday, 14 September 2016 at 05:58:51 UTC, Vadim Lopatin CSI-with-modifier codes: \e[1; this is common format for keys with modifiers, actually. let me quote my rawtty2: bool xtermMods (uint mci) @nogc { switch (mci) { case 2: key.shift = true; return true; case 3: key.alt = true; return true; case 4: key.alt = true; key.shift = true; return true; case 5: key.ctrl = true; return true; case 6: key.ctrl = true; key.shift = true; return true; case 7: key.alt = true; key.ctrl = true; return true; case 8: key.alt = true; key.ctrl = true; key.shift = true; return true; default: } return false; } void xtermSpecial (char ch) @nogc { switch (ch) { case 'A': key.key = TtyKey.Key.Up; break; case 'B': key.key = TtyKey.Key.Down; break; case 'C': key.key = TtyKey.Key.Right; break; case 'D': key.key = TtyKey.Key.Left; break; case 'E': key.key = TtyKey.Key.Pad5; break; case 'H': key.key = TtyKey.Key.Home; break; case 'F': key.key = TtyKey.Key.End; break; case 'P': key.key = TtyKey.Key.F1; break; case 'Q': key.key = TtyKey.Key.F2; break; case 'R': key.key = TtyKey.Key.F3; break; case 'S': key.key = TtyKey.Key.F4; break; case 'Z': key.key = TtyKey.Key.Tab; key.ch = 9; if (!key.shift && !key.alt && !key.ctrl) key.shift = true; break; default: badCSI(); break; } }
Beta D 2.071.2-b5
Fifth and hopefully last beta for the 2.071.2 release. This comes with two more fixes for Issue 16031 and 16460. http://dlang.org/changelog/2.071.2.html http://dlang.org/download.html#dmd_beta Please report any bugs at https://issues.dlang.org -Martin
Re: DlangUI 0.9.0: Console backend added
On Wednesday, 14 September 2016 at 13:04:40 UTC, ketmar wrote: in my editor i'm simply using rgb in [0..255] range, and mapping that to what terminal has. yet it is probably not the best way to make something nice looking when only 16 colors are available. heh, i should try and see how it will look like! ;-) actually, it's not that bad, i expected much worser results. original 256 color mode: http://ketmar.no-ip.org/img/tui/tui_c256.png and this is restricted to basic 16 colors: http://ketmar.no-ip.org/img/tui/tui_c16a.png still readable. my terminal has somewhat non-standard first 16 colors (some colors are brighter than default xterm, some are not), that's probably why background becomes so bright. but it is still readable. and this is 16 colors with "weighted translation" (0.30*r+0.59*g+0.11*b). looks surprisingly clean: http://ketmar.no-ip.org/img/tui/tui_c16b.png
Re: DlangUI 0.9.0: Console backend added
On Wed, Sep 14, 2016 at 3:11 PM, ketmar via Digitalmars-d-announce < digitalmars-d-announce@puremagic.com> wrote: > On Wednesday, 14 September 2016 at 13:08:18 UTC, Rory McGuire wrote: > >> Screenshots here are what can be done with terminal/ascii: >> http://caca.zoy.org/wiki/libcaca >> > > still, you can't use shading charaters to color text, so 16 colors for > text output won't look that impressive. ;-) > :) true
Re: Beta D 2.071.2-b5
On Wednesday, 14 September 2016 at 12:16:51 UTC, Martin Nowak wrote: Fifth and hopefully last beta for the 2.071.2 release. This comes with two more fixes for Issue 16031 and 16460. LDC master is up-to-date with 2.071.2-b5!
Re: DlangUI 0.9.0: Console backend added
On Wednesday, 14 September 2016 at 13:08:18 UTC, Rory McGuire wrote: Screenshots here are what can be done with terminal/ascii: http://caca.zoy.org/wiki/libcaca still, you can't use shading charaters to color text, so 16 colors for text output won't look that impressive. ;-)
Re: DlangUI 0.9.0: Console backend added
On Wed, Sep 14, 2016 at 3:04 PM, ketmar via Digitalmars-d-announce < digitalmars-d-announce@puremagic.com> wrote: > On Wednesday, 14 September 2016 at 05:58:51 UTC, Vadim Lopatin wrote: > >> Thank you! >> Now dlangui terminal mode supports only 16 colors. >> Some refactoring is required to support RGB colors. >> > > in my editor i'm simply using rgb in [0..255] range, and mapping that to > what terminal has. yet it is probably not the best way to make something > nice looking when only 16 colors are available. heh, i should try and see > how it will look like! ;-) > Screenshots here are what can be done with terminal/ascii: http://caca.zoy.org/wiki/libcaca
Re: Beta D 2.071.2-b5
On 09/14/2016 05:58 AM, Johan Engelen wrote: On Wednesday, 14 September 2016 at 12:16:51 UTC, Martin Nowak wrote: Fifth and hopefully last beta for the 2.071.2 release. This comes with two more fixes for Issue 16031 and 16460. LDC master is up-to-date with 2.071.2-b5! Wow! LDC is just 42 minutes behind dmd. I wonder when it will pass it. :p Ali
Re: Beta D 2.071.2-b5
On Wed, Sep 14, 2016 at 4:04 PM, Ali Çehreli via Digitalmars-d-announce < digitalmars-d-announce@puremagic.com> wrote: > On 09/14/2016 05:58 AM, Johan Engelen wrote: > >> On Wednesday, 14 September 2016 at 12:16:51 UTC, Martin Nowak wrote: >> >>> Fifth and hopefully last beta for the 2.071.2 release. >>> >>> This comes with two more fixes for Issue 16031 and 16460. >>> >> >> LDC master is up-to-date with 2.071.2-b5! >> > > Wow! LDC is just 42 minutes behind dmd. I wonder when it will pass it. :p > > Ali > > :D, this does make me wonder why the ddmd frontend is inside the compiler repos.
Re: DlangUI 0.9.0: Console backend added
On Tuesday, 13 September 2016 at 13:40:32 UTC, ketmar wrote: On Tuesday, 13 September 2016 at 12:29:47 UTC, Vadim Lopatin wrote: Screenshots on imgur: http://imgur.com/a/eaRiT btw. please note that on most GNU/Linux terminals you can use simple RGB colors (with each component in [0..5] range). IRL if $TERM != "Linux", it is safe to assume that terminal supports 256 colors (with rare exclustions like "screen" -- those can be safely ignored, screen is fubared anyway ;-). Thank you! Now dlangui terminal mode supports only 16 colors. Some refactoring is required to support RGB colors.
Re: Beta D 2.071.2-b4
On 2016-09-13 16:00, Martin Nowak wrote: There will be another beta tomorrow or so to include at least one more fix (for Issue 16460) and we'll soon release 2.071.2. This is a good moment to double check whether all the deprecation warnings for your project caused by the import changes are justified. I still have this issue: https://issues.dlang.org/show_bug.cgi?id=15857 -- /Jacob Carlborg
Re: DlangUI 0.9.0: Console backend added
On Tuesday, 13 September 2016 at 12:50:02 UTC, Rory McGuire wrote: Did you get my post about the keyboard thing? You can test it by running dub --single filename.d output looks like: kp: [27, 91, 49, 59, 50, 68] kp: [27, 91, 49, 59, 53, 68] kp: [27, 91, 49, 59, 51, 68] kp: [27, 91, 68] if I press: shift+Left ctrl+Left alt+left left Single modifiers are working ok for me. But some combinations - do not. E.g. Ctrl+Shift+Left/Up/Down - at least in Gnome terminal. BTW: love what you are doing with dlangui. Are you a one person team? In general, yes. But there were 24 contributors who sent pull requests. Some of them contributed a lot of PRs - e.g. g4z3r(54 commits), MyLittleRobo(20 commits). It would be great if more developers joined dlangui. But it should become more usable and popular, to attract more people. One of stopper here is probably poor documentation.
Re: Beta D 2.071.2-b4
On Wed, Sep 14, 2016 at 9:30 AM, Ali Çehreli via Digitalmars-d-announce < digitalmars-d-announce@puremagic.com> wrote: > On 09/12/2016 12:47 AM, Martin Nowak wrote: > > > This comes with a different fix for Issue 15907 than 2.071.2-b3. > > Kisses and hugs! :) > > Ali > > +1, this is _way_ better.