aboutsummaryrefslogtreecommitdiffstats
path: root/tagit
diff options
context:
space:
mode:
authorMatthias Baumgartner <dev@igsor.net>2023-03-05 19:16:22 +0100
committerMatthias Baumgartner <dev@igsor.net>2023-03-05 19:16:22 +0100
commit5e88d395dee651175a277092c712249e3898a7d8 (patch)
treee6e0b475c7ab5c6a7ff4f0ea7ad1b08cecf05e68 /tagit
parent54c1f6f845765fa7ed8720bbbc0130d99fc7a123 (diff)
downloadtagit-5e88d395dee651175a277092c712249e3898a7d8.tar.gz
tagit-5e88d395dee651175a277092c712249e3898a7d8.tar.bz2
tagit-5e88d395dee651175a277092c712249e3898a7d8.zip
build fixes
Diffstat (limited to 'tagit')
-rw-r--r--tagit/__init__.py3
-rw-r--r--tagit/apps/desktop.py4
-rw-r--r--tagit/external/setproperty/README.md24
-rw-r--r--tagit/external/setproperty/build.py5
-rw-r--r--tagit/external/setproperty/preprocess.py8
-rw-r--r--tagit/external/setproperty/setup.py1
6 files changed, 42 insertions, 3 deletions
diff --git a/tagit/__init__.py b/tagit/__init__.py
index b0c602d..8c4285a 100644
--- a/tagit/__init__.py
+++ b/tagit/__init__.py
@@ -20,6 +20,9 @@ import collections
import os
import typing
+import kivy.config
+kivy.config.Config.set('input', 'mouse', 'mouse,disable_multitouch')
+
# kivy imports
from kivy.resources import resource_add_path
import kivy
diff --git a/tagit/apps/desktop.py b/tagit/apps/desktop.py
index 913f922..149bf30 100644
--- a/tagit/apps/desktop.py
+++ b/tagit/apps/desktop.py
@@ -32,8 +32,8 @@ def load_data_hook(cfg, store):
import pickle
import os
# fetch data_hook config flags
- schema_path = cfg('session', 'data_hook', 'schema')
- triples_path = cfg('session', 'data_hook', 'triples')
+ schema_path = os.path.expanduser(cfg('session', 'data_hook', 'schema'))
+ triples_path = os.path.expanduser(cfg('session', 'data_hook', 'triples'))
# load data if present
if os.path.exists(schema_path) and os.path.exists(triples_path):
with open(schema_path, 'rb') as ifile:
diff --git a/tagit/external/setproperty/README.md b/tagit/external/setproperty/README.md
index e579132..4849b6c 100644
--- a/tagit/external/setproperty/README.md
+++ b/tagit/external/setproperty/README.md
@@ -1,5 +1,27 @@
-build with
+# SetProperty
+
+Analigous to kivy.properties.ListProperty, SetProperty provides a wrapper
+that extends python's set() with [Kivy](https://kivy.org) events.
+
+## Installation
+
+Note that you'll need Cython to run the following commands.
+Install Cython via:
+
+$ pip install Cython
+
+or via your system's package manager (e.g., ``sudo apt install cython``).
+
+Then, cythonize the SetProperty with:
+
+$ python preprocess.py
+
+build the shared library from cythonized with:
+
+$ python build.py build_ext --inplace
+
+or perform both steps with one command:
$ python setup.py build_ext --inplace
diff --git a/tagit/external/setproperty/build.py b/tagit/external/setproperty/build.py
new file mode 100644
index 0000000..9b3d6ab
--- /dev/null
+++ b/tagit/external/setproperty/build.py
@@ -0,0 +1,5 @@
+
+from distutils.core import Extension, setup
+ext = Extension(name="setproperty", sources=["setproperty.c"])
+setup(ext_modules=[ext])
+
diff --git a/tagit/external/setproperty/preprocess.py b/tagit/external/setproperty/preprocess.py
new file mode 100644
index 0000000..7c85b86
--- /dev/null
+++ b/tagit/external/setproperty/preprocess.py
@@ -0,0 +1,8 @@
+
+from distutils.core import Extension
+from Cython.Build import cythonize
+
+ext = Extension(name="setproperty", sources=["setproperty.pyx"])
+cythonize(ext)
+
+
diff --git a/tagit/external/setproperty/setup.py b/tagit/external/setproperty/setup.py
index 8500340..bd95d70 100644
--- a/tagit/external/setproperty/setup.py
+++ b/tagit/external/setproperty/setup.py
@@ -4,3 +4,4 @@ from Cython.Build import cythonize
# define an extension that will be cythonized and compiled
ext = Extension(name="setproperty", sources=["setproperty.pyx"])
setup(ext_modules=cythonize(ext))
+