Implemented node browser and micron parser link handling.

This commit is contained in:
Mark Qvist 2021-08-27 19:58:14 +02:00
parent 6a36786c4d
commit 6e4baf3731
7 changed files with 635 additions and 30 deletions

View file

@ -64,6 +64,7 @@ class GuideEntry(urwid.WidgetWrap):
def __init__(self, app, reader, topic_name):
self.app = app
self.reader = reader
self.last_keypress = None
g = self.app.ui.glyphs
widget = ListEntry(topic_name)
@ -76,10 +77,13 @@ class GuideEntry(urwid.WidgetWrap):
def display_topic(self, event, topic):
markup = TOPICS[topic]
attrmaps = markup_to_attrmaps(markup)
attrmaps = markup_to_attrmaps(markup, url_delegate=None)
self.reader.set_content_widgets(attrmaps)
def micron_released_focus(self):
self.reader.focus_topics()
class TopicList(urwid.WidgetWrap):
def __init__(self, app, guide_display):
self.app = app
@ -142,12 +146,21 @@ class GuideDisplay():
def shortcuts(self):
return self.shortcuts_display
def focus_topics(self):
self.columns.focus_position = 0
TOPIC_INTRODUCTION = '''>Nomad Network
`c`*Communicate Freely.`*
`a
TODO: REMOVE
This is a `F07flink `[With a label`344858860838a8d9f8ed:/page/test] to some resource`f.
This is a link `*`[With a label`:/page/test]`* to some resource.
This is a link `[With a label`:] to some resource.
This is a link `*`[With a label`344858860838a8d9f8ed] to some`* resource.
The intention with this program is to provide a tool to that allows you to build private and resilient communications platforms that are in complete control and ownership of the people that use them.
Nomad Network is build on LXMF and Reticulum, which together provides the cryptographic mesh functionality and peer-to-peer message routing that Nomad Network relies on. This foundation also makes it possible to use the program over a very wide variety of communication mediums, from packet radio to gigabit fiber.