semvec/pypi-packages huggingface dataset:
userpaths 0.1.3
Cross-platform access to a user's special folders

The **userpaths** module provides cross-platform access to a user's special folders (or directories) like My Documents, Desktop, and Application Data. It is primarily intended to simplify development of desktop application software.

A quick usage example:

```python
# Get the user's My Documents folder
import userpaths
my_docs = userpaths.get_my_documents()
```

Both Python 2 and 3 are supported, on Windows and Unix platforms.


## API Reference

Function | Description
-------- | -----------
`get_appdata()` | Return the current user's roaming Application Data folder.
`get_desktop()` | Return the current user's Desktop folder.
`get_downloads()` | Return the current user's Downloads folder.
`get_local_appdata()` | Return the current user's local Application Data folder.
`get_my_documents()` | Return the current user's My Documents folder.
`get_my_music()` | Return the current user's My Music folder.
`get_my_pictures()` | Return the current user's My Pictures folder.
`get_my_videos()` | Return the current user's My Videos folder.
`get_profile()` | Return the current user's profile folder.

The userpaths API was inspired by, and is partly compatible with, Ryan Ginstrom's [winpaths](http://ginstrom.com/code/winpaths.html). However, userpaths is not intended as a direct replacement for that module.


## Compatibility Note

The userpaths module was originally designed from a Windows-centric perspective. Because of the many differences between the two systems, there are some Windows paths that do not have a direct equivalent on Unix, and vice versa. In these cases, userpaths attempts to return the nearest functional equivalent, but it is up to the user to ensure their application is using the appropriate path for what it seeks to do.
tkFilterList 0.1.2
Self-filtering Listbox with text entry for Tkinter

**tkFilterList** is a combination of the Tkinter Listbox and Entry widgets that updates to display matching items as you type.


## Usage

tkFilterList consists of a single module, `tkfilterlist` (note the module name is lowercase), which exports a single class, `FilterList`.

A brief example program:

```python
#!/usr/bin/env python3

from tkinter import *
from tkinter.messagebox import showinfo
from tkfilterlist import FilterList
import operator

# Source items for the FilterList
# Format: display_text, symbol, operator
source = [("Addition", "+", operator.add),
          ("Subtraction", "-", operator.sub),
          ("Multiplication", "*", operator.mul),
          ("Division", "/", operator.floordiv)]

# Create a root window
root = Tk()

# Create a FilterList widget
fl = FilterList(root,
                source=source,
                display_rule=lambda item: item[0],
                filter_rule=lambda item, text:
                            item[0].lower().startswith(text.lower()))
fl.pack(side="top", expand=1, fill="both")

def show_result(event=None):
    a, b = 42, 7
    item = fl.selection()
    if item:
        showinfo("Result",
                 "{0} {1} {2} = {3}".format(a, item[1], b, item[2](a, b)),
                 parent=root)

# Show the result of the calculation on Return or double-click
fl.bind("<Return>", show_result)
fl.bind("<Double-Button-1>", show_result)

# Focus on the FilterList widget
fl.focus_set()

# Start Tk's event loop
root.mainloop()
```

For detailed documentation, try `python -m pydoc tkfilterlist`.


## Customization

You can customize the item display and filtering behavior by setting its `display_rule` and `filter_rule` options, respectively, to your own custom functions. This allows tkFilterList to process lists containing complex datatypes, including nested lists, tuples, and even entire classes. The functions are defined as follows:

Function | Description
-------- | -----------
`display_rule(item)` | Returns the display text for the specified `item`.
`filter_rule(item, text)` | Returns `True` if the `text` argument matches the specified `item`, `False` otherwise.

The default display rule is available as `FilterList.default_display_rule`. It returns the string value of `item`, matching the behavior of a standard Listbox widget.

The default filter rule is available as `FilterList.default_filter_rule`. It returns `True` if an `item` starts with the specified `text` using a case-insensitive match.
tkDataCanvas 0.1.1
Tabular data display widget for Tkinter

**tkDataCanvas** is a tabular data display widget for Python + Tkinter. It is intended as a more efficient replacement for [tkMagicGrid](https://github.com/bmjcode/tkMagicGrid) and [tkScrolledFrame](https://github.com/bmjcode/tkScrolledFrame) for displaying large amounts of static data.

tkDataCanvas is designed to be simple above all else. It has no dependencies outside the Python standard library. Its API is designed to let you accomplish tasks with as few method calls as possible.

Both Python 2 and 3 are supported, on Windows and Unix platforms.

## Usage

tkDataCanvas consists of a single module, `tkdatacanvas` (note the module name is lowercase), which exports a single class, `DataCanvas`.

A brief example program:

```python
#!/usr/bin/env python3

from tkinter import *
from tkdatacanvas import DataCanvas
import io
import csv

# Create a root window
root = Tk()

# Create a DataCanvas widget
dc = DataCanvas(root)
dc.pack(side="top", expand=1, fill="both")

# Display the contents of some CSV file
with io.open("test.csv", "r", newline="") as csv_file:
    reader = csv.reader(csv_file)
    parsed_rows = 0
    for row in reader:
        if parsed_rows == 0:
    	    # Display the first row as a header
    	    dc.add_header(*row)
        else:
    	    dc.add_row(*row)
        parsed_rows += 1
dc.display()

# Start Tk's event loop
root.mainloop()
```

For detailed documentation, try `python -m pydoc tkdatacanvas`.