annotate src/cagou/plugins/__init__.py @ 58:7aa2ffff9067

chat: <img/> tag handling first draft: We need to have several widgets to handle <img/> (label(s) + image(s)), which make sizing and positioning complicated. To make things simpler, we use a simple trick when several widgets are present: we split the labels in as many labels as there are words, so we can take profit of the StackLayout. The split is done after the XHTML is parsed, so after all the widgets are present, and is done only once. This means that label need to be reparsed to be splitted. This is not perfect, but should be a reasonable solutions until we implement a real XHTML engine (probably CEF widget and Webview). image sizing and alignment is not handled correcly now, should be fixed soon.
author Goffi <goffi@goffi.org>
date Wed, 28 Sep 2016 22:02:36 +0200
parents 56838ad5c84b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source