1
0

qt: add anchor channel icon

source: https://tabler-icons.io/anchor
This commit is contained in:
bitromortac
2021-10-11 11:18:33 +02:00
committed by ThomasV
parent 9bfeffcdd1
commit f746e2cc6b
2 changed files with 9 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@@ -438,6 +438,13 @@ class ChanFeatNoOnchainBackup(ChannelFeature):
return read_QIcon("cloud_no")
class ChanFeatAnchors(ChannelFeature):
def tooltip(self) -> str:
return _("This channel uses anchor outputs.")
def icon(self) -> QIcon:
return read_QIcon("anchor")
class ChannelFeatureIcons:
def __init__(self, features: Sequence['ChannelFeature']):
@@ -458,6 +465,8 @@ class ChannelFeatureIcons:
feats.append(ChanFeatTrampoline())
if not chan.has_onchain_backup():
feats.append(ChanFeatNoOnchainBackup())
if chan.has_anchors():
feats.append(ChanFeatAnchors())
return ChannelFeatureIcons(feats)
def paint(self, painter: QPainter, rect: QRect) -> None: