qcanvas 1.2.0__py3-none-any.whl → 2026.1.19__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. qcanvas/__init__.py +60 -0
  2. qcanvas/app.py +72 -0
  3. qcanvas/backend_connectors/frontend_resource_manager.py +13 -5
  4. qcanvas/backend_connectors/qcanvas_task_master.py +2 -2
  5. qcanvas/icons/__init__.py +5 -5
  6. qcanvas/icons/_icon_type.py +1 -1
  7. qcanvas/icons/icons.qrc +39 -35
  8. qcanvas/icons/rc_icons.py +1298 -1197
  9. qcanvas/settings/__init__.py +6 -0
  10. qcanvas/{util/settings → settings}/_client_settings.py +4 -4
  11. qcanvas/settings/_course_settings.py +54 -0
  12. qcanvas/{util/settings → settings}/_mapped_setting.py +2 -5
  13. qcanvas/{util/settings → settings}/_ui_settings.py +5 -5
  14. qcanvas/theme.py +101 -0
  15. qcanvas/ui/course_viewer/content_tree.py +9 -12
  16. qcanvas/ui/course_viewer/course_tree/_course_icon_generator.py +3 -3
  17. qcanvas/ui/course_viewer/course_tree/course_tree.py +9 -8
  18. qcanvas/ui/course_viewer/course_viewer.py +42 -56
  19. qcanvas/ui/course_viewer/tabs/assignment_tab/assignment_tab.py +107 -29
  20. qcanvas/ui/course_viewer/tabs/assignment_tab/assignment_tree.py +4 -4
  21. qcanvas/ui/course_viewer/tabs/constants.py +1 -0
  22. qcanvas/ui/course_viewer/tabs/content_tab.py +33 -39
  23. qcanvas/ui/course_viewer/tabs/file_tab/file_tab.py +4 -4
  24. qcanvas/ui/course_viewer/tabs/file_tab/file_tree.py +7 -10
  25. qcanvas/ui/course_viewer/tabs/file_tab/pages_file_tree.py +6 -7
  26. qcanvas/ui/course_viewer/tabs/mail_tab/mail_tab.py +50 -27
  27. qcanvas/ui/course_viewer/tabs/mail_tab/mail_tree.py +7 -8
  28. qcanvas/ui/course_viewer/tabs/page_tab/page_tab.py +3 -3
  29. qcanvas/ui/course_viewer/tabs/page_tab/page_tree.py +5 -5
  30. qcanvas/ui/course_viewer/tabs/resource_rich_browser.py +18 -32
  31. qcanvas/ui/course_viewer/tree_widget_data_item.py +1 -1
  32. qcanvas/ui/memory_tree/_tree_memory.py +45 -42
  33. qcanvas/ui/memory_tree/memory_tree_widget.py +22 -18
  34. qcanvas/ui/memory_tree/memory_tree_widget_item.py +3 -3
  35. qcanvas/ui/qcanvas_window/__init__.py +1 -0
  36. qcanvas/ui/{main_ui → qcanvas_window}/course_viewer_container.py +10 -10
  37. qcanvas/ui/{main_ui → qcanvas_window}/options/auto_download_resources_option.py +5 -5
  38. qcanvas/ui/{main_ui → qcanvas_window}/options/quick_sync_option.py +7 -6
  39. qcanvas/ui/{main_ui → qcanvas_window}/options/sync_on_start_option.py +7 -6
  40. qcanvas/ui/{main_ui → qcanvas_window}/options/theme_selection_menu.py +10 -10
  41. qcanvas/ui/{main_ui → qcanvas_window}/qcanvas_window.py +57 -41
  42. qcanvas/ui/{main_ui → qcanvas_window}/status_bar_progress_display.py +5 -6
  43. qcanvas/ui/qml_components/__init__.py +4 -0
  44. qcanvas/ui/qml_components/attachments_pane.py +70 -0
  45. qcanvas/ui/qml_components/comments_pane.py +83 -0
  46. qcanvas/ui/qml_components/qml/AttachmentsList.ui.qml +15 -0
  47. qcanvas/ui/qml_components/qml/AttachmentsListDelegate.qml +77 -0
  48. qcanvas/ui/qml_components/qml/AttachmentsListModel.qml +19 -0
  49. qcanvas/ui/qml_components/qml/AttachmentsPane.qml +11 -0
  50. qcanvas/ui/qml_components/qml/CommentsList.ui.qml +15 -0
  51. qcanvas/ui/qml_components/qml/CommentsListDelegate.ui.qml +118 -0
  52. qcanvas/ui/qml_components/qml/CommentsListModel.qml +56 -0
  53. qcanvas/ui/qml_components/qml/CommentsPane.qml +11 -0
  54. qcanvas/ui/qml_components/qml/DecoratedText.ui.qml +44 -0
  55. qcanvas/ui/qml_components/qml/Spacer.ui.qml +7 -0
  56. qcanvas/ui/qml_components/qml/ThemedRectangle.qml +53 -0
  57. qcanvas/ui/qml_components/qml/__init__.py +3 -0
  58. qcanvas/ui/qml_components/qml/rc_qml.py +709 -0
  59. qcanvas/ui/qml_components/qml/rc_qml.qrc +16 -0
  60. qcanvas/ui/qml_components/qml_bridge_types.py +95 -0
  61. qcanvas/ui/qml_components/qml_pane.py +21 -0
  62. qcanvas/ui/setup/setup_checker.py +1 -1
  63. qcanvas/ui/setup/setup_dialog.py +28 -14
  64. qcanvas/util/auto_downloader.py +9 -7
  65. qcanvas/util/basic_fonts.py +2 -2
  66. qcanvas/util/context_dict.py +12 -0
  67. qcanvas/util/file_icons.py +11 -19
  68. qcanvas/util/layouts.py +5 -7
  69. qcanvas/util/paths.py +17 -6
  70. qcanvas/util/qurl_util.py +1 -1
  71. qcanvas/util/ui_tools.py +118 -8
  72. qcanvas/util/url_checker.py +1 -1
  73. qcanvas-2026.1.19.dist-info/METADATA +95 -0
  74. qcanvas-2026.1.19.dist-info/RECORD +92 -0
  75. {qcanvas-1.2.0.dist-info → qcanvas-2026.1.19.dist-info}/WHEEL +1 -1
  76. qcanvas-2026.1.19.dist-info/entry_points.txt +3 -0
  77. qcanvas/app_start/__init__.py +0 -59
  78. qcanvas/icons/_update_icons.py +0 -89
  79. qcanvas/icons/dark/actions/exit.svg +0 -3
  80. qcanvas/icons/dark/actions/mark_all_read.svg +0 -3
  81. qcanvas/icons/dark/actions/open_downloads.svg +0 -3
  82. qcanvas/icons/dark/actions/quick_login.svg +0 -3
  83. qcanvas/icons/dark/actions/sync.svg +0 -3
  84. qcanvas/icons/dark/branding/logo_transparent.svg +0 -303
  85. qcanvas/icons/dark/options/auto_download.svg +0 -3
  86. qcanvas/icons/dark/options/theme.svg +0 -3
  87. qcanvas/icons/dark/tabs/assignments.svg +0 -3
  88. qcanvas/icons/dark/tabs/mail.svg +0 -3
  89. qcanvas/icons/dark/tabs/pages.svg +0 -3
  90. qcanvas/icons/dark/tree_items/assignment.svg +0 -3
  91. qcanvas/icons/dark/tree_items/mail.svg +0 -3
  92. qcanvas/icons/dark/tree_items/module.svg +0 -3
  93. qcanvas/icons/dark/tree_items/page.svg +0 -3
  94. qcanvas/icons/light/actions/exit.svg +0 -3
  95. qcanvas/icons/light/actions/mark_all_read.svg +0 -3
  96. qcanvas/icons/light/actions/open_downloads.svg +0 -3
  97. qcanvas/icons/light/actions/quick_login.svg +0 -3
  98. qcanvas/icons/light/actions/sync.svg +0 -3
  99. qcanvas/icons/light/branding/logo_transparent.svg +0 -304
  100. qcanvas/icons/light/options/auto_download.svg +0 -3
  101. qcanvas/icons/light/options/ignore_old.svg +0 -3
  102. qcanvas/icons/light/options/include_videos.svg +0 -3
  103. qcanvas/icons/light/options/theme.svg +0 -3
  104. qcanvas/icons/light/tabs/assignments.svg +0 -3
  105. qcanvas/icons/light/tabs/mail.svg +0 -3
  106. qcanvas/icons/light/tabs/pages.svg +0 -3
  107. qcanvas/icons/light/tree_items/assignment.svg +0 -3
  108. qcanvas/icons/light/tree_items/mail.svg +0 -3
  109. qcanvas/icons/light/tree_items/module.svg +0 -3
  110. qcanvas/icons/light/tree_items/page.svg +0 -3
  111. qcanvas/icons/universal/branding/main_icon.svg +0 -325
  112. qcanvas/icons/universal/downloads/download_failed.svg +0 -23
  113. qcanvas/icons/universal/downloads/downloaded.svg +0 -23
  114. qcanvas/icons/universal/downloads/not_downloaded.svg +0 -23
  115. qcanvas/icons/universal/downloads/unknown.svg +0 -6
  116. qcanvas/icons/universal/tabs/assignments_new_content.svg +0 -3
  117. qcanvas/icons/universal/tabs/mail_new_content.svg +0 -3
  118. qcanvas/icons/universal/tabs/pages_new_content.svg +0 -3
  119. qcanvas/icons/universal/tree_items/semester.svg +0 -108
  120. qcanvas/run.py +0 -54
  121. qcanvas/ui/course_viewer/tabs/util.py +0 -11
  122. qcanvas/ui/main_ui/__init__.py +0 -0
  123. qcanvas/util/settings/__init__.py +0 -9
  124. qcanvas/util/themes/__init__.py +0 -2
  125. qcanvas/util/themes/_colour_scheme_helper.py +0 -38
  126. qcanvas/util/themes/_selected_theme.py +0 -10
  127. qcanvas/util/themes/_theme_changed_event.py +0 -17
  128. qcanvas/util/themes/_theme_changer.py +0 -86
  129. qcanvas-1.2.0.dist-info/METADATA +0 -71
  130. qcanvas-1.2.0.dist-info/RECORD +0 -118
  131. qcanvas-1.2.0.dist-info/entry_points.txt +0 -3
  132. /qcanvas/ui/{main_ui → qcanvas_window}/options/__init__.py +0 -0
@@ -0,0 +1,56 @@
1
+ import QtQuick
2
+
3
+ ListModel {
4
+ ListElement {
5
+ body: "This is a comment. Gaze at it. Be amazed."
6
+ author: "I am Steve"
7
+ date: "2001-01-01 36:00"
8
+ attachments: [
9
+ ListElement {
10
+ file_name: "texas.pdf"
11
+ resource_id: "1"
12
+ download_state: "NOT_DOWNLOADED"
13
+ },
14
+ ListElement {
15
+ file_name: "oh_no_what_a_terribly_long_file_name_its_not_like_someone_would_actually_do_this.pdf"
16
+ resource_id: "2"
17
+ download_state: "FAILED"
18
+ },
19
+ ListElement {
20
+ file_name: "i was transported to another world where javascript doesn't exist.cbz"
21
+ resource_id: "3"
22
+ download_state: "DOWNLOADED"
23
+ }
24
+ ]
25
+ }
26
+ ListElement {
27
+ body: "If Morbius has a million fans, I am one of them.\nIf Morbius has 5 fans, I am one of them.\nIf Morbius has one fan, That one is me.\nIf Morbius has no fans, I am no longer alive.\nIf the world is against Morbius, I am against the world.\nTill my last breath, I'll love Morbius (2022)."
28
+ author: "Goku"
29
+ date: "1942-16-34 06:63"
30
+ attachments: [
31
+ ListElement {
32
+ file_name: "morbius_x264_1080.mkv"
33
+ resource_id: "blahblah"
34
+ download_state: "NOT_DOWNLOADED"
35
+ }
36
+ ]
37
+ }
38
+ ListElement {
39
+ body: "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\nbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb"
40
+ author: "Word Wrap Test"
41
+ date: "2000-02-02"
42
+ attachments: []
43
+ }
44
+ ListElement {
45
+ body: "x264 forms the core of many web video services, such as Youtube, Facebook, Vimeo, and Hulu. It is widely used by television broadcasters and ISPs."
46
+ author: "BideoJAN Wordsblahblah"
47
+ date: "2027-07-28"
48
+ attachments: [
49
+ ListElement {
50
+ file_name: "Ass1_SOMEDUDE_48.pdf"
51
+ resource_id: "blah_v345"
52
+ download_state: "DOWNLOADED"
53
+ }
54
+ ]
55
+ }
56
+ }
@@ -0,0 +1,11 @@
1
+ import QtQuick
2
+
3
+ ThemedRectangle {
4
+ anchors.fill: parent
5
+
6
+ CommentsList {
7
+ anchors.fill: parent
8
+ model: comments
9
+ palette: theme
10
+ }
11
+ }
@@ -0,0 +1,44 @@
1
+ import QtQuick
2
+ import QtQuick.Controls
3
+ import QtQuick.Layouts
4
+
5
+ Item {
6
+ property alias text: content.text
7
+ property int lineWidth: 3
8
+ property color lineColour: palette.accent
9
+ property alias content: content
10
+
11
+ Layout.fillWidth: true
12
+ height: content.contentHeight
13
+ clip: true
14
+
15
+ Item {
16
+ anchors.fill: parent
17
+ height: content.contentHeight
18
+
19
+ Rectangle {
20
+ id: decoration
21
+ width: lineWidth
22
+ color: lineColour
23
+ radius: 1
24
+ anchors {
25
+ left: parent.left
26
+ top: parent.top
27
+ bottom: parent.bottom
28
+ }
29
+ }
30
+
31
+ Text/*Edit*/ {
32
+ id: content
33
+ Layout.fillWidth: true
34
+ color: palette.text
35
+ //readOnly: true
36
+ //textFormat: TextEdit.AutoText
37
+ anchors {
38
+ left: decoration.right
39
+ leftMargin: 10
40
+ right: parent.right
41
+ }
42
+ }
43
+ }
44
+ }
@@ -0,0 +1,7 @@
1
+ import QtQuick
2
+
3
+ Item {
4
+ property real size
5
+ height: size
6
+ width: 1
7
+ }
@@ -0,0 +1,53 @@
1
+ import QtQuick
2
+
3
+ Rectangle {
4
+ property Palette theme: getTheme()
5
+ color: theme.base
6
+
7
+ function getTheme() {
8
+ if (appTheme.theme === "native")
9
+ return palette
10
+ else if (appTheme.dark_mode === true)
11
+ return darkTheme
12
+ else
13
+ return lightTheme
14
+ }
15
+
16
+ Palette {
17
+ id: lightTheme
18
+ base: "#f8f9fa"
19
+ window: "#f8f9fa"
20
+ midlight: "#f8f9fa"
21
+ accent: "#e02424"
22
+ link: accent
23
+ dark: "#dadce0"
24
+ text: "#4d5157"
25
+ }
26
+
27
+ Palette {
28
+ id: darkTheme
29
+ base: "#202124"
30
+ window: "#f8f9fa"
31
+ midlight: "#202124"
32
+ accent: "#e02424"
33
+ link: accent
34
+ dark: "#3f4042"
35
+ text: "#e4e7eb"
36
+ }
37
+
38
+ Connections {
39
+ target: appTheme
40
+
41
+ function onThemeChanged() {
42
+ updateTheme()
43
+ }
44
+
45
+ function onDarkModeChanged() {
46
+ updateTheme()
47
+ }
48
+
49
+ function updateTheme() {
50
+ theme = getTheme()
51
+ }
52
+ }
53
+ }
@@ -0,0 +1,3 @@
1
+ import logging
2
+
3
+ _logger = logging.getLogger(__name__)