Package: tinengine
TinEngineA advanced tkinter widget for Tin-lang.内置一个基于tkinter的富文本渲染组件——TinText，可以将Tin标记文本渲染为富文本。installpython-mpipinstalltinengineorpip install tinenginerequireTin需要以下第三方库。| Tin needs these packages.PIL(pillow) - load images while rendering.requests - get content from web.pythonnet - use clr.pywebview - for WebView2.tkinterweb - for hype text in TinText.What is TinTin标记语言是一个语言规范，也是一个文本格式，以标记为主。具体见：Tin知识库。Tin is a markup language, and Tin is also a format of text file.For more information, see"about Tin".Why is TinTin可应用在以下几个方面：将Tin标记文本渲染为易读的富文本进行阅读，这是Tin的最初目的基于tkinter，实现类似于HTMLlayout的Tinlayout，这是Tin正在努力的将格式、数据、信息进行样式化呈现，这是每个富文本的通用功能这是Tin相较于其他tkinter拓展最独特的。Tin can be used in these situation:Render Tin marked text into easy-to-read rich text for reading, it's the original purpose of Tin.Based on tkinter, Tinlayout similar to HTMLlayout can be realized, which Tin is trying to improve.Style presentation of format, data and information is the general function of  every rich text language.This is the most unique ability of Tin compared with other tkinter's extended widgets and libs.Use Tin based PythonTinText==TinText==是TinEngine的核心组件，是负责将Tin标记文本渲染为易读的富文本。TinText is the main widget of TinEngine, which is responsible for rendering Tin markup text into easy-to-read rich text.TinText的主要函数是point_file，这将实现渲染功能。函数定义以及参数如下：The main function of TinText ispoint_file, which will realize the rendering function. The function definition and parameters are as follows:defpoint_file(self,unit:str,cls:int=0,insert:str='end',*arg)->(str,int):#-2.3.0-版本，unit使用list；-2.3.1-及以上版本，unit使用str'''unit::Tin标记文本段 | Text segment marked by Tincls::是否清空，若为值1，本轮操作清空文本框 | Clear, if it is 1, the text box will be cleared in this operationinsert::渲染的起始位置 | Start position of rendering'''关于TinText的初始化参数，详见：参考文章。See the initialization parameters of TinText for details, see"about TinText Class".Demo实际上，拓展包里的__init__.py文件就是一个例子。下面是更加简单的使用方法。fromtkinterimport*fromtinengine.TinEngineimportTinTexttin='''<title>Tin的测试<main>这是关于Tin标记文本应用于TinText的一个demo。<main>Tin是世界上第一个可用tkinter系统地渲染的标记语言。'''a=Tk()a.geometry('750x500')t=TinText(a,font=('微软雅黑',12))t.pack(fill='both',expand=True)#-2.3.0-版本：t.point_file(tin.split('\n'))#-2.3.1-及以上版本：t.point_file(tin)a.mainloop()Actually, the__init__.pyfile in the extension package is an example. The following is a simpler way to use it.fromtkinterimport*fromtinengine.TinEngineimportTinTexttin='''<title>Test of TinText<main>This is a demo about the useage of Tin marked text on TinText.<main>Tin is the first markup language that can be rendered systematically by tkinter.'''a=Tk()a.geometry('750x500')t=TinText(a,font=('微软雅黑',12))t.pack(fill='both',expand=True)#-2.3.0- version use this：#t.point_file(tin.split('\n'))#-2.3.1- version and above use this：t.point_file(tin)a.mainloop()Use Tin based Tin使用TinEngine，就要知道Tin标记语言。以下是获取Tin标记语言规范的方式：在Tin知识库下载软件TinReader，附带Tin标记说明从coding库下载使用说明的压缩包To use TinEngine, you need to know Tin markup language. The following is how to get the Tin markup language specification:Download the software TinReader inTin knowledge basewith Tin tag instructionsDownload the compressed package of instructions from theCoding libraryCall me如果你有什么想法或者是问题，可以告诉我。If you have some problems or great ideas, you can tell me. (If I have enough time, I am a student, actually.)使用邮件：smart-space@qq.comUse e-mail to report me:smart-space@qq.comWhat's new-2.5.0-fix loading<hptext>and<html>in a child thread.using the newest tkinterweb version.add<quo>to add a quote text.add<sst>to show subscript and superscript text.add<rtf>to render *.rtf file (in\data\depend\) in TinText.-2.4.0-Now you can use<table>with TinUI's table if you want.Use@LBK@in<table>if you want to start a newline of a item with using TinUI's table control.Use WebView2 to render html. But it can't be rendered in a child thread, and reader can render it by using a tip button later.<stop>won't delay so much in Main Thread.-2.3.9-<tinframe>allows you to add a TinText widget in your *.tin file rendering.You can use<depend>to download necessary files while rendering.-2.3.7-<mode>can get more args as a sentence with line breaks.<download>can download files using multithreading.Add<topic>to show the main idea of what TinText is rendering.-2.3.6-<do>is added into TinText to run scripts with out calling.We continue to make tables in TinText more beautiful and add args to<code>. And TinUI support is  available.-2.3.5-We add<download>, which can allow reader to download a file or not.As well, It is better to render the tables written in TinText.-2.3.2-It uses the ieframe fo show the<html>.A frame will be added in TinText while asking a key do render more.-2.3.1-An epoch-making version. It has a more powerful engine. Speed, Performance, and stability all have been promoted.-2.3.0-Upload to PYPI. But the first verstion ofTinEngine.pydis calledTinEngine-2.1.3.You can find more information about the versions of TinEngine inTin-version. TinReader's versions and news on rendering are the same as TinEngine's.