Commit Graph

782 Commits

Author SHA1 Message Date
Andreas Kling
7455f5ea42 Expose the kernel log buffer through /proc/dmesg.
Also add a /bin/dmesg program for convenience.
2019-01-28 22:40:55 +01:00
Andreas Kling
442351a5f8 Tweak .gitignore. 2019-01-28 20:38:53 +01:00
Andreas Kling
dbeac6e093 LibGUI: Reduce overdraw in GListBox. 2019-01-28 20:38:13 +01:00
Andreas Kling
c95228b128 Add support for removing directories.
It's really only supported in Ext2FS since SynthFS doesn't really want you
mucking around with its files. This is pretty neat though :^)

I ran into some trouble with HashMap while working on this but opted to work
around it and leave that for a separate investigation.
2019-01-28 04:16:01 +01:00
Andreas Kling
031c62a21e .bochsrc: Toggle mouse grab with ctrl-alt (works nicer on 1-button mice.) 2019-01-28 02:34:09 +01:00
Andreas Kling
83228d03d8 LibGUI: GButton should only react to the left mouse button (for pushing.) 2019-01-27 20:26:45 +01:00
Andreas Kling
35c06f1520 LibGUI: More work on GCheckBox.
- Make it track the mouse cursor just like GButton does so that changes only
  get committed if the mouseup event happens while inside the widget rect.

- Draw a focus rect around the box when appropriate.

- When focused, support toggling the checked state with the space bar.
2019-01-27 20:22:06 +01:00
Andreas Kling
90e898b771 GTextBox: Avoid one instance of overdraw + naming cleanup. 2019-01-27 15:12:33 +01:00
Andreas Kling
0e73aa36c8 Kernel: Unbreak symbolication yet another time. 2019-01-27 10:17:56 +01:00
Andreas Kling
6d351bb326 Kernel: Move RAM size detection to MemoryManager and use what we learn. 2019-01-27 10:17:27 +01:00
Andreas Kling
c4c475b49d /bin/cp: Handle partial write() case. 2019-01-27 10:04:53 +01:00
Andreas Kling
32755aeb60 Tweak .gitignore 2019-01-27 09:50:11 +01:00
Andreas Kling
069d21ed7f Make buttons unpress when the cursor leaves the button rect.
Implement this functionality by adding global cursor tracking.
It's currently only possible for one GWidget per GWindow to track the cursor.
2019-01-27 08:48:34 +01:00
Andreas Kling
15fad649ea Userland: Make a simple /bin/cp for copying files. 2019-01-27 07:18:26 +01:00
Andreas Kling
a34bb07abb Make .bochsrc work with the stock Bochs on Ubuntu. 2019-01-27 07:17:24 +01:00
Andreas Kling
c7221b7dee Painter: Tell the compiler to flatten Font::draw_glyph().
I think that concludes the Terminal stress test optimizations for now.
2019-01-27 05:23:04 +01:00
Andreas Kling
c7b005c47b Font: Eagerly load all 256 glyphs. It's not that many. 2019-01-27 05:19:00 +01:00
Andreas Kling
2e370fa4d5 LibGUI: Don't consider a GWidget focused if the window is inactive. 2019-01-26 21:58:43 +01:00
Andreas Kling
25d045dee5 LibGUI: Reduce GEventLoop debug spam. 2019-01-26 21:44:13 +01:00
Andreas Kling
de2423de5f LibGUI: Flesh out focus implementation and more GTextBox work. 2019-01-26 11:24:16 +01:00
Andreas Kling
d72575d196 LibGUI: Start bringing up GTextBox in the standalone world. 2019-01-26 06:39:13 +01:00
Andreas Kling
57fb027216 LibC: Implement setjmp() and longjmp().
I think this is correct. The following registers are saved and restored:
EBX, ESI, EDI, EBP, ESP and EIP.
2019-01-26 06:25:24 +01:00
Andreas Kling
f34c0e414b WindowServer: Remove unused WSMessage::is_paint_event(). 2019-01-26 05:49:04 +01:00
Andreas Kling
9fa8d4e22f WindowServer: Rename the two painting phases.
Work now happens in terms of two messages:

    - WM_ClientWantsToPaint
    - WM_ClientFinishedPaint

This feels fairly obvious compared to the old Paint/Invalidate.
2019-01-26 05:45:47 +01:00
Andreas Kling
244d5bcce1 WindowServer: More event -> message renaming. 2019-01-26 05:35:45 +01:00
Andreas Kling
bba21adae3 WindowServer: Rename WSEvent to WSMessage.
Also do the same for WSMessageLoop and WSMessageReceiver. More to come.
2019-01-26 05:28:02 +01:00
Andreas Kling
7cf3c7461c Refactor GUI rendering model to be two-phased.
Instead of clients painting whenever they feel like it, we now ask that they
paint in response to a paint message.

After finishing painting, clients notify the WindowServer about the rect(s)
they painted into and then flush eventually happens, etc.

This stuff leaves us with a lot of badly named things. Need to fix that.
2019-01-26 05:20:32 +01:00
Andreas Kling
3a401d5249 LibC: Oops, unbreak isprint() once again. 2019-01-25 16:21:29 +01:00
Andreas Kling
6208cef154 Liza8x10: Tweak 'o' glyph. 2019-01-25 15:55:17 +01:00
Andreas Kling
a54848f451 Let's not auto-start guitest. guitest2 is so much more useful. 2019-01-25 15:52:55 +01:00
Andreas Kling
6e5db34b2e sh: Discard the current line on interrupt. 2019-01-25 15:49:54 +01:00
Andreas Kling
c6fdde37e7 Liza8x10: Minor glyph tweaks. 2019-01-25 15:43:19 +01:00
Andreas Kling
92c14ba887 Terminal: Support VKILL and VERASE. Also ignore null characters. 2019-01-25 15:34:21 +01:00
Andreas Kling
d059e684a2 Keyboard: Shift+backspace should generate backspace character. 2019-01-25 15:34:02 +01:00
Andreas Kling
8fa7d96f50 SharedGraphics: Import another 8x10 fixed-width font I made.
It's not perfect yet but it's quite nice to look at so I'll make this the
system default for now. :^)
2019-01-25 15:33:47 +01:00
Andreas Kling
6cc1a9d90a sh: Support basic backspacing on the command line.
It's weird that I didn't do this sooner. I don't know how many tims
I've had to retype a misspelled command. :^)
2019-01-25 15:11:56 +01:00
Andreas Kling
dfdca9d2a7 Kernel: Implement lazy FPU state restore. 2019-01-25 07:52:44 +01:00
Andreas Kling
2279f5eaa6 SharedGraphics: Fix broken clipping in draw_bitmap(). 2019-01-25 06:37:56 +01:00
Andreas Kling
5adaeeaa3b Terminal: Support setting the window title using Xterm escape sequences.
Use this in the /bin/sh prompt to keep the window title in sync with the
shell's working directory. :^)
2019-01-25 05:52:16 +01:00
Andreas Kling
5f14e22a31 WindowServer: Make dragging window frames look kinda cool. 2019-01-25 05:19:45 +01:00
Andreas Kling
d39f585f35 Kernel: Fix Syscall.h build when out of context. 2019-01-25 05:19:29 +01:00
Andreas Kling
0db72786cf Snazz up the windows with some title bar gradients. :^) 2019-01-25 05:02:32 +01:00
Andreas Kling
c6b7b92625 WindowServer: Put the desktop background color in a member. 2019-01-25 03:48:50 +01:00
Andreas Kling
623847cf6d Terminal: Tweak dark blue color. 2019-01-25 03:24:52 +01:00
Andreas Kling
a915dd7b27 WindowServer: Retain window backing stores while blitting them. 2019-01-25 03:07:55 +01:00
Andreas Kling
8a3af99416 SharedGraphics: Optimize Painter::draw_bitmap().
Manually peel as much as possible out of the loop for a ~100% speedup.
2019-01-25 02:39:45 +01:00
Andreas Kling
267a903dd0 Terminal: Redraw entire line if any of its characters are dirty.
This means we only have to do one fill_rect() per line and the whole process
ends up being ~10% faster than before.

Also added a read_tsc() syscall to give userspace access to the TSC.
2019-01-25 02:09:29 +01:00
Andreas Kling
11b73c38d8 Kernel: Fix incorrect EFAULTs when syscall would write into COW pages. 2019-01-25 01:39:15 +01:00
Andreas Kling
a4a106a430 Terminal: Use a more reasonable data structure for the emulation buffer. 2019-01-25 01:27:02 +01:00
Andreas Kling
e28de4ad5e Kernel: Dump registers and code on ring0 page fault. 2019-01-25 00:32:50 +01:00