Commit graph

9327 commits

Author SHA1 Message Date
Yonatan Goldschmidt
c377e6af29 Ports: Add preliminary dropbear port
This is very basic and doesn't support many features. Instead
of describing what it *doesn't* support, I'll describe what I
have tested:
1. Public key authentication (password is not supported)
2. Single command execution
3. PTY-less interactive bash shell (/bin/sh doesn't work)
4. Multi-user (i.e you can ssh as 'anon' as well as root)
2020-05-11 09:50:42 +02:00
Yonatan Goldschmidt
b03fefd9f8 LibC: Add minimal <netinet/ip.h>
It's based on <netinet/in.h> and more definitions might be required
here (e.g, IP header).
2020-05-11 09:50:42 +02:00
Yonatan Goldschmidt
d3bb6cf5a9 LibC: Add missing <sys/time.h> include in <utmp.h>
This file uses 'struct timeval' without including relevant header.
2020-05-11 09:50:42 +02:00
Yonatan Goldschmidt
6c4fe69899 LibC: Add inet_aton, based on inet_pton 2020-05-11 09:50:42 +02:00
Yonatan Goldschmidt
107c83bd42 Kernel+LibC: Add AF_MAX
Will be updated as we add more protocols (e.g AF_INET6)
2020-05-11 09:50:42 +02:00
Yonatan Goldschmidt
6571468525 LibC: Return nullptr in fgets for size=0
I had this assert trigger, I believe in a legitimate case.
This is the behavior glic and musl follow.
2020-05-11 09:50:42 +02:00
Ben Wiederhake
ebe47de0b2 LibGfx: Eliminate conditional branch in dither
In theory, this should make dithering a teensy bit faster.
2020-05-11 09:47:32 +02:00
AnotherTest
c88c883f44 LibLine: Show suggestions in pages if they don't fit on the screen
We can now cycle pages of suggestions when there are more suggestions
than we can fit on one screen.
This does not inculude a visual indicator that more pages exist,
however.
2020-05-11 09:33:18 +02:00
AnotherTest
5b9fe0cf46 LibVT: Update the terminal buffer based on visible lines
Lines in the history should not be considered for update at all.
Fixes #2185
2020-05-11 09:33:18 +02:00
Ben Wiederhake
87b6578516 FontEditor: Fix link to icon after it moved
Fixup for 6f2837cb13
2020-05-11 09:29:30 +02:00
Brian Callahan
f660fd2aef Ports: Build ncurses --without-ada to avoid potential build failures. 2020-05-10 22:40:51 +02:00
Andreas Kling
d612ca1fcc LibWeb: Render content based on MIME type provided by server (or guess)
We now look at the Content-Type HTTP header when deciding how to render
some loaded content. If there is no Content-Type header (which will
always be the case when loading local files, for example), we make a
guess based on the URL filename.
2020-05-10 22:32:12 +02:00
Andreas Kling
20f50f9133 LibProtocol: Pass response headers in a case insensitive HashMap
HTTP headers are case-insensitive, so just add CaseInsensitiveTraits
to the HashMap and we're good to go! :^)
2020-05-10 22:32:12 +02:00
Andreas Kling
aef5d28828 Browser: Allow opening URLs by dropping them on the HtmlView :^) 2020-05-10 22:32:12 +02:00
Andreas Kling
fc26aefe81 LibWeb: Add a hook for when an URL is dropped on an HtmlView
Embedders of HtmlView can now react to this by hooking on_url_drop.
2020-05-10 22:32:12 +02:00
Andreas Kling
f1708b3832 LibWeb: Teach HtmlView how to render Markdown files :^) 2020-05-10 22:32:12 +02:00
Andreas Kling
97adcde36e LibWeb: Teach HtmlView how to open a .txt file
When encountering a text file, we now put it in a wrapper document with
the file contents in a <pre> tag. This works really nicely :^)
2020-05-10 22:32:12 +02:00
Andreas Kling
0e60e7aef0 LibWeb: Add Document create_element() and create_text_node() helpers 2020-05-10 22:32:12 +02:00
Andreas Kling
9d7ab13b32 LibWeb: Add Text to the forwarding header 2020-05-10 22:32:12 +02:00
Andreas Kling
f2058a39bf WindowServer: Shade the bottom of the menu bar like a button
This adds a row of secondary (darker) shade to the menubar, giving it
a more buttonish look to match the highlight added to the Taskbar. :^)
2020-05-10 22:32:12 +02:00
Andreas Kling
4e766c8159 Taskbar: Let's custom paint the background instead of using GUI::Frame
Previously we were wasting the bottom pixel row on darkness. Use the
base button color all the way to the bottom row and offset the top
highlight by one pixel instead.
2020-05-10 22:32:12 +02:00
Brian Callahan
f15b467b5d Ports: Add dash shell 2020-05-10 19:42:48 +02:00
Brian Callahan
092bda2f14 Ports: Add tr utility 2020-05-10 19:41:35 +02:00
Brian Callahan
baf6efb46f Ports: Fix binutils runtime 2020-05-10 19:41:09 +02:00
Linus Groh
4c1a765076 LibWeb: Add basic support for "border-style: {dotted,dashed}" 2020-05-10 19:41:00 +02:00
Linus Groh
0669dbcf5d LibGfx: Add support for dashed lines
Non-configurable for now.
2020-05-10 19:41:00 +02:00
Andreas Kling
3667677008 ls: Emit hyperlinks for files outside the current directory 2020-05-10 17:48:41 +02:00
Andreas Kling
666863c2d8 LibVT: Clear the hovered hyperlink after completing a drag 2020-05-10 17:42:24 +02:00
Andreas Kling
f41bbdd46e LibVT: Allow dragging hyperlinks :^)
You can now drag a hyperlink as a text/uri-list. This allows you to
drag a file from "ls" output and drop it on a FileManager to copy
the file there. Truly futuristic stuff!
2020-05-10 17:39:11 +02:00
Andreas Kling
901d2e3236 LibVT: Make selection follow terminal history scrollback :^)
The buffer positions referred to by a VT::Position now include history
scrollback, meaning that a VT::Position with row=0 is at the start of
the history.

The active terminal buffer keeps moving in VT::Position coordinates
whenever we scroll. This allows selection to follow history. It also
allows us to click hyperlinks in history.

Fixes #957.
2020-05-10 16:59:02 +02:00
Andreas Kling
c50672a19d Shell: Hyperlink output from "pwd" and "dirs" built-ins :^) 2020-05-10 16:24:59 +02:00
Andreas Kling
8af3af137e LibVT: Use the "ActiveLink" theme color for links being clicked
Okay, links are finally starting to feel visually intuitive. :^)
2020-05-10 16:14:49 +02:00
Andreas Kling
ab7de41c7b LibVT: Don't commit to opening a hyperlink until mouseup
It felt too rushed to open links when simply mousedown'ing on them.
Improve this by implementing basic "click" semantics instead.

This patch also introduces the ability to prevent link opening if you
want to force selection instead. Hold shift and we will not open links.
2020-05-10 16:01:08 +02:00
Andreas Kling
c6f098c5a9 WindowServer: Add 2px of tasteful space above maximized windows
This makes the visual interaction between the menu bar and the window
a lot less janky looking.
2020-05-10 14:46:23 +02:00
Andreas Kling
61e112d3b7 DisplaySettings: Tweak app icon 2020-05-10 14:40:36 +02:00
Andreas Kling
fce0cf18e3 LibGfx: Make buttons slightly chunkier on the top/left side 2020-05-10 14:24:20 +02:00
Andreas Kling
5af4ad097f Base: Open .font files in FontEditor again
This broke when we introduced LaunchServer.
2020-05-10 14:24:04 +02:00
Andreas Kling
c10c6240f2 LibVT: Open hyperlinks on plain left-click instead of Ctrl+Click 2020-05-10 13:45:04 +02:00
Andreas Kling
3226276fe9 LibVT: Always draw hyperlinks with a dotted underline
The dotted line is custom painted to put some more distance between the
dots than what Painter::draw_line() does.
2020-05-10 13:43:56 +02:00
Linus Groh
d3d29ea1cc Demos: Add LibGfx Demo :^) 2020-05-10 13:34:59 +02:00
Linus Groh
59d00e5df6 LibGfx: Replace 'bool dotted' with a LineStyle::{Solid,Dotted} enum
Just a bool is insufficient as we'll have to support dashed lines as well.
2020-05-10 13:34:59 +02:00
Linus Groh
da42279171 LibGfx: Fix dotted lines with thickness > 1
If we just skip every second pixel, we still get a solid line if each
"pixel" is wider than 1!
Now we skip the same amount of pixels as the line is thick.
2020-05-10 13:34:59 +02:00
Shannon Booth
eb43e2d544 WindowServer: Add basic search functionality in menus
Perform a case insensitive search through the current menu. Jump to the
first item matching all keys in the current search. Backspace can clear
the current search, and the search will timeout after 3 seconds.
2020-05-10 13:34:51 +02:00
Shannon Booth
d5c40899cb WindowServer: Rework and simplify Menu event handling
The menu manager will now send events directly to the current menu.
Previously if a menu was opened it would always be set as the current
menu. Now when opening a menu you can optionally say that you do not
want to have it as the current menu.

One scenerio when this happens is when a menu is popped up as part of a
preview, for example, when hovering over a menu item that is a submenu.

Sending the event to the current menu simplifies things and solves a few
inconsistencies in bevhaviour (such as hovering over a submenu, but key
events not being sent to the submenu).
2020-05-10 13:34:51 +02:00
Shannon Booth
b1c83e5a64 WindowServer: Remove stray semicolon 2020-05-10 13:34:51 +02:00
Andreas Kling
5fcd25e8f6 Browser: Use "about:blank" as the default home page
This can be overridden in Browser.ini, but if there's no value there,
we now use "about:blank"
2020-05-10 11:18:47 +02:00
Andreas Kling
fe0de26277 LibWeb+Browser: Support about: URL protocol so "about:blank" works :^)
For now, we simply load an empty resource from any about: URL.
2020-05-10 11:14:30 +02:00
Andreas Kling
56dbe58bbb AK: Add support for about: URLs 2020-05-10 11:11:48 +02:00
AnotherTest
6b674db855 Shell: Support basic syntax highlighting 2020-05-10 10:23:05 +02:00
AnotherTest
c40fd3a902 LibLine: Support RGB colors
This also patches Userland/js.
2020-05-10 10:23:05 +02:00