Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add method for load html content #173

Open
NikitaPnch opened this issue Jan 16, 2025 · 0 comments
Open

Please add method for load html content #173

NikitaPnch opened this issue Jan 16, 2025 · 0 comments

Comments

@NikitaPnch
Copy link

Hi, thank you for webview linux package, i want to display raw html content inside linux webview

I try to fork package and override loadUrl method something like this

void WebviewHandler::loadUrl(int browserId, std::string url)
{
    std::stringstream ss;
    ss << "<html><body bgcolor=\"white\"><h2>Failed to load URL</h2></body></html>";
    auto it = browser_map_.find(browserId);
    if (it != browser_map_.end()) {
        it->second.browser->GetMainFrame()->LoadURL(GetDataURI(url, "text/html"));
    }
}

but i have some problem with display huge html causing crash my app or html just dont load

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant