Skip to content

Commit

Permalink
browser/gui: Use SFML for text measurements when layouting
Browse files Browse the repository at this point in the history
  • Loading branch information
robinlinden committed Nov 20, 2023
1 parent 291bcc9 commit fa0cc1b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions browser/gui/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ cc_binary(
"//os:system_info",
"//protocol",
"//render",
"//type:sfml",
"//uri",
"//util:history",
"@fmt",
Expand Down
4 changes: 3 additions & 1 deletion browser/gui/app.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include "gfx/sfml_canvas.h"
#include "layout/layout_box.h"
#include "protocol/handler_factory.h"
#include "type/sfml.h"
#include "uri/uri.h"
#include "util/history.h"

Expand All @@ -35,7 +36,8 @@ class App final {
private:
// Latest Firefox ESR user agent (on Windows). This matches what the Tor browser does.
engine::Engine engine_{protocol::HandlerFactory::create(
"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0")};
"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Firefox/102.0"),
std::make_unique<type::SfmlType>()};
bool page_loaded_{};

std::string browser_title_{};
Expand Down

0 comments on commit fa0cc1b

Please sign in to comment.