summaryrefslogtreecommitdiff
path: root/DevTools
AgeCommit message (Collapse)Author
2019-12-24LibGUI+LibDraw: Add "Palette" concept for scoped color themingAndreas Kling
GApplication now has a palette. This palette contains all the system theme colors by default, and is inherited by a new top-level GWidget. New child widgets inherit their parents palette. It is possible to override the GApplication palette, and the palette of any GWidget. The Palette object contains a bunch of colors, each corresponding to a ColorRole. Each role has a convenience getter as well. Each GWidget now has a background_role() and foreground_role(), which are then looked up in their current palette when painting. This means that you no longer alter the background color of a widget by setting it directly, rather you alter either its background role, or the widget's palette.
2019-12-24LibDraw: Add Selection and SelectionText system theme colorsAndreas Kling
2019-12-23WindowServer+LibGUI: Implement basic color themingAndreas Kling
Color themes are loaded from .ini files in /res/themes/ The theme can be switched from the "Themes" section in the system menu. The basic mechanism is that WindowServer broadcasts a SharedBuffer with all of the color values of the current theme. Clients receive this with the response to their initial WindowServer::Greet handshake. When the theme is changed, WindowServer tells everyone by sending out an UpdateSystemTheme message with a new SharedBuffer to use. This does feel somewhat bloated somehow, but I'm sure we can iterate on it over time and improve things. To get one of the theme colors, use the Color(SystemColor) constructor: painter.fill_rect(rect, SystemColor::HoverHighlight); Some things don't work 100% right without a reboot. Specifically, when constructing a GWidget, it will set its own background and foreground colors based on the current SystemColor::Window and SystemColor::Text. The widget is then stuck with these values, and they don't update on system theme change, only on app restart. All in all though, this is pretty cool. Merry Christmas! :^)
2019-12-23HackStudio: Show the project name as the root in the project treeAndreas Kling
2019-12-23HackStudio: Sort the project tree alphabeticallyAndreas Kling
I had to turn the tree nodes into RefCounted objects since it's not possible to quick_sort() a Vector<OwnPtr<T>> at the moment.
2019-12-23HackStudio: Show the project file list in a tree viewAndreas Kling
Replace the boring list view with an awesome tree view :^)
2019-12-20Build: clean up build system, use one shared Makefilejoshua stein
Allow everything to be built from the top level directory with just 'make', cleaned with 'make clean', and installed with 'make install'. Also support these in any particular subdirectory. Specifying 'make VERBOSE=1' will print each ld/g++/etc. command as it runs. Kernel and early host tools (IPCCompiler, etc.) are built as object.host.o so that they don't conflict with other things built with the cross-compiler.
2019-12-17ProfileViewer: Make initial invert checkbox match initial tree viewOhad Rau
The "Invert tree" checkbox was accidentally defaulted to display true when the actual tree wasn't being inverted, causing the checkbox to say the opposite of the tree state initially. This change just brings the visual indicator in line with what the code is actually doing.
2019-12-16ProfileViewer: Ignore empty samplesAndreas Kling
Sometimes we get empty samples in a profile. I'm not sure why that happens, but let's just ignore them for now.
2019-12-16ProfileViewer: Add the ability to invert the profile treeAndreas Kling
Inverting the tree turns all of the innermost stack frames into roots, allowing them to accumulate their total sample counts with other instances of the same frame being innermost. This is an essential feature of any cool profiler, and now we have it. :^)
2019-12-15ProfileViewer: Add a basic menu bar to make it look properAndreas Kling
2019-12-15ProfileViewer: Scale the sample columns by stack depthAndreas Kling
From a nice suggestion by Nagy Tibor. :^)
2019-12-15ProfileViewer: Convert the JSON samples into a more efficient formatAndreas Kling
Only do the conversion from JSON once. This makes it much faster to do time range filtering with the timeline widget. :^)
2019-12-15ProfileViewer: Fix copy-paste error :^)gla3dr
Saw this copy-paste mistake in the ProfileViewer Timeline video
2019-12-14ProfileViewer: Precompute the timestamp and "in kernel?" per sampleAndreas Kling
Instead of fetching these from JSON in every paint event, we now have a separate "SampleData" vector that can be iterated. This optimization was made possible by profiling ProfileViewer and then analyzing the profile with ProfileViewer! :^)
2019-12-14ProfileViewer: Allow filtering samples in a specific time rangeAndreas Kling
You can now select the time range you want on the profile timeline. The tree view will update automatically as you alter the range. Unfortunately this causes the treeview to collapse all of its nodes. It would be nice to solve this somehow in the future so that nodes can stay open.
2019-12-14ProfileViewer: Add a timeline widget for a visual view of the profileAndreas Kling
Userspace stack frames are in blue, kernel stack frames in red :^)
2019-12-14IPCCompiler: Use const references for message constructor parametersAndreas Kling
2019-12-14ProfileViewer: Show kernel frames with a red icon :^)Andreas Kling
2019-12-13ProfileViewer: Use the new multi-column tree model support in GTreeViewAndreas Kling
Put the sample count into a separate column. This is so neat :^)
2019-12-12ProfileViewer: Make sure ProfileNodes have the correct parent pointerAndreas Kling
We were forgetting to call ProfileNode::add_child() which is how the parent node pointer gets set. This fixes the weird looking GTreeView.
2019-12-12ProfileViewer: Begin work on a visualization tool for profiles :^)Andreas Kling
We begin with a simple treeview that shows a recorded profile. To record and view a profile of a process with <PID>, simply do this: $ profile <PID> on ... wait while PID does something interesting ... $ profile <PID> off $ cat /proc/profile > my-profile.prof $ ProfileViewer my-profile.prof
2019-12-10HackStudio: Use a table view in the "find in files" widgetAndreas Kling
Make the results of a "find in files" operation look a lot nicer by presenting them in a table format, instead of in a single-column list. Since we don't yet support rich text in table view cells, use the marker glyphs in the system default fixed-width font to show where the matched text begins and ends on the line we found it on. :^)
2019-12-09LibGUI: Make GMenu inherit from CObjectAndreas Kling
This is primarily to make it possible to pass a GMenu* where a CObject* is expected.
2019-12-09AK: Use size_t for the length of stringsAndreas Kling
Using int was a mistake. This patch changes String, StringImpl, StringView and StringBuilder to use size_t instead of int for lengths. Obviously a lot of code needs to change as a result of this.
2019-12-02LibIPC: Rename IMessage id/name to message_id/message_nameAndreas Kling
Hogging "id" and "name" makes it impossible to use these as message parameter names, which seems silly. :^)
2019-12-02WindowServer: Port to the new IPC systemAndreas Kling
This patch introduces code generation for the WindowServer IPC with its clients. The client/server endpoints are defined by the two .ipc files in Servers/WindowServer/: WindowServer.ipc and WindowClient.ipc It now becomes significantly easier to add features and capabilities to WindowServer since you don't have to know nearly as much about all the intricate paths that IPC messages take between LibGUI and WSWindow. The new system also uses significantly less IPC bandwidth since we're now doing packed serialization instead of passing fixed-sized structs of ~600 bytes for each message. Some repaint coalescing optimizations are lost in this conversion and we'll need to look at how to implement those in the new world. The old CoreIPC::Client::Connection and CoreIPC::Server::Connection classes are removed by this patch and replaced by use of ConnectionNG, which will be renamed eventually. Goodbye, old WindowServer IPC. You served us well :^)
2019-12-02HackStudio: Fixes CppLexer crashing on a comment block that doesSasan Hezarkhani
not end. CppLexer expected that `/*` always has `*/` at the end. This PR fixes the issue and assumes the rest of file is a comment.
2019-11-26Kernel: Expose per-thread information in /proc/allAndreas Kling
Previously it was not possible to see what each thread in a process was up to, or how much CPU it was consuming. This patch fixes that. SystemMonitor and "top" now show threads instead of just processes. "ps" is gonna need some more fixing, but it at least builds for now. Fixes #66.
2019-11-24LibHTML: Use LibProtocol for HTTP requests :^)Andreas Kling
This moves all of the browser networking to ProtocolServer.
2019-11-23IPCCompiler: Add support for String parameters in messagesAndreas Kling
2019-11-23HackStudio: Highlight matching pairs of [ and ] as wellAndreas Kling
Also refactor the token pair matching code a little bit to not repeat ourselves so much. :^)
2019-11-23LibIPC+AudioServer: Allow unsolicited server-to-client IPC messagesAndreas Kling
Client-side connection objects must now provide both client and server endpoint types. When a message is received from the server side, we try to decode it using both endpoint types and then send it to the right place for handling. This now makes it possible for AudioServer to send unsolicited messages to its clients. This opens up a ton of possibilities :^)
2019-11-18HackStudio: Always re-match curlies/parens after a re-highlightAndreas Kling
While you are typing in HackStudio, we re-lex the C++ as you type, so this means we also need to keep re-checking for matching curlies and parentheses at the cursor. Fixes #769 (although it's not optional, because it's too cool. :^)
2019-11-18HackStudio: Highlight maching parentheses as wellAndreas Kling
This can just piggyback on the code I just wrote for curly braces.
2019-11-18HackStudio+LibGUI: Implement matching curly brace highlightingAndreas Kling
This works for C++ syntax highlighted text documents by caching the C++ token type in a new "arbitrary data" member of GTextDocumentSpan. When the cursor is placed immediately before a '{' or immediately after a '}', we highlight both of these brace buddies by changing their corresponding spans to have a different background color. ..and spans can also now have a custom background color. :^)
2019-11-17LibDraw: Add Rect::from_two_points(Point, Point)Andreas Kling
This returns the rectangle between two given Points. Thanks Owlinator for suggesting this much easier way of doing it :^)
2019-11-16HackStudio: Move the rubber-banding state into CursorToolAndreas Kling
I originally put it in FormWidget because CursorTool was clueless about painting. This patch adds Tool::on_second_paint() which allows all the tools to hook into the second paint pass.
2019-11-16HackStudio: Fill the selection rubber-band with some nice alpha colorAndreas Kling
Make use of the new alpha support in Painter::fill_rect() to fill the rubber band with some see-through color. :^)
2019-11-16HackStudio: Allow rubber-band selection of widgetsAndreas Kling
This patch implements basic rubber-banding. Perhaps this mechanism can be generalized somehow, but it's not clear to me how that would work at the moment.
2019-11-15HackStudio: Mark whitespace tokens as skippable GTextDocumentSpansAndreas Kling
This makes Ctrl+Left/Right jump over whitespace, which feels nice :^)
2019-11-14HackStudio: Add a Stop action to kill the current processSergey Bugaev
Also give the Run action a different icon that has the same style as the stop icon that's now alongside it. Closes https://github.com/SerenityOS/serenity/issues/771
2019-11-14HackStudio: Do not spawn an intermediary shellSergey Bugaev
The Shell also puts each command into its own process group, which interferes with us trying to do the same here. We don't really need the shell here anyway, but it means we'll have to do command splitting ourselves.
2019-11-14HackStudio: Add TerminalWrapper::kill_running_command()Sergey Bugaev
Also put our child process into a new process group in order to be able to kill it along with its own children.
2019-11-14HackStudio: Add TerminalWrapper::on_command_exitSergey Bugaev
2019-11-13LibPthread: Start working on a POSIX threading libraryAndreas Kling
This patch adds pthread_create() and pthread_exit(), which currently simply wrap our existing create_thread() and exit_thread() syscalls. LibThread is also ported to using LibPthread.
2019-11-13Terminal+HackStudio: Fix leaking PTM fd to child processesSergey Bugaev
The pseudoterminal *master* fd is not supposed to be inherited, so make sure to open it with O_CLOEXEC.
2019-11-11HackStudio: Reflect widget selections in the form widget tree viewAndreas Kling
You can now manipulate the widget selection either by clicking and dragging the widgets using the cursor tool, or by interacting with the form widget tree view. :^)
2019-11-11HackStudio: Show the edited form widget's widget tree in the tree viewAndreas Kling
This patch introduces a simple WidgetTreeModel that models the widget tree inside of a given root GWidget.
2019-11-10HackStudio: Make the widget toolbar buttons checkable and exclusiveAndreas Kling
This way you can see which tool you've currently got selected, and it doesn't let you select more than one at once.