-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path__init__.py
More file actions
42 lines (34 loc) · 1.33 KB
/
Copy path__init__.py
File metadata and controls
42 lines (34 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/usr/bin/env python
# -*- coding: utf-8 -*-
__license__ = 'GPL v3'
__copyright__ = '2025, Mickaël Rémond'
__docformat__ = 'restructuredtext en'
from calibre.customize import InterfaceActionBase
class ReMarkableSync(InterfaceActionBase):
'''
Plugin to sync books with reMarkable tablet via desktop app
'''
name = 'reMarkable Sync'
description = 'Send books to reMarkable Paper Pro Move via desktop app and sync reading positions'
supported_platforms = ['osx', 'windows', 'linux']
author = 'Mickaël Rémond'
version = (1, 0, 0)
minimum_calibre_version = (5, 0, 0)
actual_plugin = 'calibre_plugins.remarkable_sync.ui:ReMarkableSyncAction'
def is_customizable(self):
return True
def config_widget(self):
from calibre_plugins.remarkable_sync.config import ConfigWidget
from calibre.gui2 import gui_prefs
cw = ConfigWidget()
# Try to get database access for custom columns
try:
from calibre.gui2.ui import get_gui
gui = get_gui()
if gui and hasattr(gui, 'current_db'):
cw.populate_custom_columns(gui.current_db)
except Exception:
pass # Config can work without db access
return cw
def save_settings(self, config_widget):
config_widget.save_settings()