From 6084e104d5c3868196c9e2d3748c6627cf983470 Mon Sep 17 00:00:00 2001 From: bptato Date: Fri, 12 Mar 2021 20:52:44 +0100 Subject: Replaced parser, readline, etc... --- main.nim | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'main.nim') diff --git a/main.nim b/main.nim index b2ce1ace..677b812f 100644 --- a/main.nim +++ b/main.nim @@ -29,7 +29,6 @@ proc getPageUri(uri: Uri): Stream = if uri.scheme == "" or uri.scheme == "file": return getLocalPage($moduri) else: - #return nparseHtml(getRemotePage($moduri)) return getRemotePage($moduri) var buffers: seq[Buffer] @@ -44,9 +43,9 @@ proc main*() = let buffer = newBuffer(attrs) let uri = parseUri(paramStr(1)) buffers.add(buffer) - buffer.document = nparseHtml(getPageUri(uri)) + buffer.document = parseHtml(getPageUri(uri)) buffer.setLocation(uri) - buffer.nrenderHtml() + buffer.renderHtml() var lastUri = uri while displayPage(attrs, buffer): statusMsg("Loading...", buffer.height) @@ -58,10 +57,9 @@ proc main*() = if uri.scheme == "" and uri.path == "" and uri.anchor != "": discard else: - buffer.document = nparseHtml(getPageUri(buffer.document.location)) - buffer.nrenderHtml() + buffer.document = parseHtml(getPageUri(buffer.document.location)) + buffer.renderHtml() lastUri = newUri #waitFor loadPage("https://lite.duckduckgo.com/lite/?q=hello%20world") -#eprint mk_wcswidth_cjk("abc•de") main() -- cgit 1.4.1-2-gfad0