Skip to main content
coloring pencils!

tttt - tims tkinter text tags

Save and load tags for the tkinter text widget using open office format xml

Features

  • Super easy to use api, All the commands you will need are below!

  • Automatically indent buttons on selection

  • Bold, Italic, Underline, Overstrike, Fonts, Sizes

  • Behavour of adding and removing tags is modeled on libre office

Installation

pip3 install tttt

Usage

There is a demo picture avaliable

from tttt import XmlManager

tag_manager = XmlManager(text)

bind these to your callback buttons or hotkeys

tag_manager.change_style('bold')
tag_manager.change_style('italic')
tag_manager.change_style('solid')                       # underline
tag_manager.change_style(('family',value))
tag_manager.change_style(('size',value))
tag_manager.change_style(('foreground', value))
tag_manager.change_style(('background', value))

Saving and loading

tag_manager.load(data)
xml_data = tag_manager.save()

Configuring Buttons For Indenting

tag_manager.button_references = {'bold':bold,
                                'italic':italic,
                                'underline':underline,
                                'family':family_font_menu.var,
                                'overstrike':overstrike,
                                'foreground':foreground,
                                'background':background,
                                'size':size_menu.var
                                }

Coming Next Release

  • copy/paste/saving formatted text

  • python2 support

Change log

0.1.3

  • bug fix - duplicating tags on save/load

0.1.2

  • overstrike added

  • bold/italic buttons etc will no longer steal focus from the widget

0.1.1

  • many bugs removed

Authors and Contributors

Timothy Eichler

Release files for tttt 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tttt 0.1.3
File Size Uploaded
tttt-0.1.3.zip 25.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for tttt 0.1.3
File Interpreter ABI Platform
tttt-0.1.3-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 46.7 kB

Release files / tttt-0.1.3.zip

Download URL tttt-0.1.3.zip
Size 25.2 kB
Tags Source
SHA-256 checksum
How to use checksums
770383ba7a4b1e997acac3ee8aab418230e90b8bfce0d881b094a3daf7e8bdbd
BLAKE2b-256 checksum
How to use checksums
225df84437dacd5b63feef223890dc1c0f553226b06ea2cf4dfe043dd8eb53f1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / tttt-0.1.3-py2.py3-none-any.whl

Download URL tttt-0.1.3-py2.py3-none-any.whl
Size 21.4 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
9897c5ddf2679354ecbddaa35881377e9f7068a49bd324eb99f4cb40ea33fc2d
BLAKE2b-256 checksum
How to use checksums
d329dec72eda381d63669c2f31ac44abbb6fc9d122afaba0f5cf142753077753
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page