figrecipe 0.5.0__py3-none-any.whl → 0.7.4__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.
- figrecipe/__init__.py +220 -819
- figrecipe/_api/__init__.py +48 -0
- figrecipe/_api/_extract.py +108 -0
- figrecipe/_api/_notebook.py +61 -0
- figrecipe/_api/_panel.py +46 -0
- figrecipe/_api/_save.py +191 -0
- figrecipe/_api/_seaborn_proxy.py +34 -0
- figrecipe/_api/_style_manager.py +153 -0
- figrecipe/_api/_subplots.py +333 -0
- figrecipe/_api/_validate.py +82 -0
- figrecipe/_dev/__init__.py +29 -0
- figrecipe/_dev/_plotters.py +76 -0
- figrecipe/_dev/_run_demos.py +56 -0
- figrecipe/_dev/demo_plotters/__init__.py +64 -0
- figrecipe/_dev/demo_plotters/_categories.py +81 -0
- figrecipe/_dev/demo_plotters/_figure_creators.py +119 -0
- figrecipe/_dev/demo_plotters/_helpers.py +31 -0
- figrecipe/_dev/demo_plotters/_registry.py +50 -0
- figrecipe/_dev/demo_plotters/bar_categorical/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/bar_categorical/plot_bar.py +25 -0
- figrecipe/_dev/demo_plotters/bar_categorical/plot_barh.py +25 -0
- figrecipe/_dev/demo_plotters/contour_surface/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_contour.py +30 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_contourf.py +29 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_tricontour.py +28 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_tricontourf.py +28 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_tripcolor.py +29 -0
- figrecipe/_dev/demo_plotters/contour_surface/plot_triplot.py +25 -0
- figrecipe/_dev/demo_plotters/distribution/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/distribution/plot_boxplot.py +24 -0
- figrecipe/_dev/demo_plotters/distribution/plot_ecdf.py +24 -0
- figrecipe/_dev/demo_plotters/distribution/plot_hist.py +24 -0
- figrecipe/_dev/demo_plotters/distribution/plot_hist2d.py +25 -0
- figrecipe/_dev/demo_plotters/distribution/plot_violinplot.py +25 -0
- figrecipe/_dev/demo_plotters/image_matrix/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_hexbin.py +25 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_imshow.py +23 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_matshow.py +23 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_pcolor.py +29 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_pcolormesh.py +29 -0
- figrecipe/_dev/demo_plotters/image_matrix/plot_spy.py +29 -0
- figrecipe/_dev/demo_plotters/line_curve/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_errorbar.py +28 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_fill.py +29 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_fill_between.py +30 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_fill_betweenx.py +28 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_plot.py +28 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_stackplot.py +29 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_stairs.py +27 -0
- figrecipe/_dev/demo_plotters/line_curve/plot_step.py +27 -0
- figrecipe/_dev/demo_plotters/scatter_points/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/scatter_points/plot_scatter.py +24 -0
- figrecipe/_dev/demo_plotters/special/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/special/plot_eventplot.py +25 -0
- figrecipe/_dev/demo_plotters/special/plot_loglog.py +27 -0
- figrecipe/_dev/demo_plotters/special/plot_pie.py +27 -0
- figrecipe/_dev/demo_plotters/special/plot_semilogx.py +27 -0
- figrecipe/_dev/demo_plotters/special/plot_semilogy.py +27 -0
- figrecipe/_dev/demo_plotters/special/plot_stem.py +27 -0
- figrecipe/_dev/demo_plotters/spectral_signal/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_acorr.py +24 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_angle_spectrum.py +28 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_cohere.py +29 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_csd.py +29 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_magnitude_spectrum.py +28 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_phase_spectrum.py +28 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_psd.py +29 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_specgram.py +30 -0
- figrecipe/_dev/demo_plotters/spectral_signal/plot_xcorr.py +25 -0
- figrecipe/_dev/demo_plotters/vector_flow/__init__.py +4 -0
- figrecipe/_dev/demo_plotters/vector_flow/plot_barbs.py +30 -0
- figrecipe/_dev/demo_plotters/vector_flow/plot_quiver.py +30 -0
- figrecipe/_dev/demo_plotters/vector_flow/plot_streamplot.py +30 -0
- figrecipe/_editor/__init__.py +278 -0
- figrecipe/_editor/_bbox/__init__.py +43 -0
- figrecipe/_editor/_bbox/_collections.py +177 -0
- figrecipe/_editor/_bbox/_elements.py +159 -0
- figrecipe/_editor/_bbox/_extract.py +256 -0
- figrecipe/_editor/_bbox/_extract_axes.py +370 -0
- figrecipe/_editor/_bbox/_extract_text.py +342 -0
- figrecipe/_editor/_bbox/_lines.py +173 -0
- figrecipe/_editor/_bbox/_transforms.py +146 -0
- figrecipe/_editor/_flask_app.py +258 -0
- figrecipe/_editor/_helpers.py +242 -0
- figrecipe/_editor/_hitmap/__init__.py +76 -0
- figrecipe/_editor/_hitmap/_artists/__init__.py +21 -0
- figrecipe/_editor/_hitmap/_artists/_collections.py +345 -0
- figrecipe/_editor/_hitmap/_artists/_images.py +68 -0
- figrecipe/_editor/_hitmap/_artists/_lines.py +107 -0
- figrecipe/_editor/_hitmap/_artists/_patches.py +163 -0
- figrecipe/_editor/_hitmap/_artists/_text.py +190 -0
- figrecipe/_editor/_hitmap/_colors.py +181 -0
- figrecipe/_editor/_hitmap/_detect.py +137 -0
- figrecipe/_editor/_hitmap/_restore.py +154 -0
- figrecipe/_editor/_hitmap_main.py +182 -0
- figrecipe/_editor/_overrides.py +318 -0
- figrecipe/_editor/_preferences.py +135 -0
- figrecipe/_editor/_render_overrides.py +480 -0
- figrecipe/_editor/_renderer.py +199 -0
- figrecipe/_editor/_routes_axis.py +453 -0
- figrecipe/_editor/_routes_core.py +284 -0
- figrecipe/_editor/_routes_element.py +317 -0
- figrecipe/_editor/_routes_style.py +223 -0
- figrecipe/_editor/_templates/__init__.py +152 -0
- figrecipe/_editor/_templates/_html.py +502 -0
- figrecipe/_editor/_templates/_scripts/__init__.py +120 -0
- figrecipe/_editor/_templates/_scripts/_api.py +228 -0
- figrecipe/_editor/_templates/_scripts/_colors.py +485 -0
- figrecipe/_editor/_templates/_scripts/_core.py +436 -0
- figrecipe/_editor/_templates/_scripts/_debug_snapshot.py +186 -0
- figrecipe/_editor/_templates/_scripts/_element_editor.py +310 -0
- figrecipe/_editor/_templates/_scripts/_files.py +195 -0
- figrecipe/_editor/_templates/_scripts/_hitmap.py +509 -0
- figrecipe/_editor/_templates/_scripts/_inspector.py +315 -0
- figrecipe/_editor/_templates/_scripts/_labels.py +464 -0
- figrecipe/_editor/_templates/_scripts/_legend_drag.py +265 -0
- figrecipe/_editor/_templates/_scripts/_modals.py +226 -0
- figrecipe/_editor/_templates/_scripts/_overlays.py +292 -0
- figrecipe/_editor/_templates/_scripts/_panel_drag.py +334 -0
- figrecipe/_editor/_templates/_scripts/_panel_position.py +279 -0
- figrecipe/_editor/_templates/_scripts/_selection.py +237 -0
- figrecipe/_editor/_templates/_scripts/_tabs.py +89 -0
- figrecipe/_editor/_templates/_scripts/_view_mode.py +107 -0
- figrecipe/_editor/_templates/_scripts/_zoom.py +179 -0
- figrecipe/_editor/_templates/_styles/__init__.py +69 -0
- figrecipe/_editor/_templates/_styles/_base.py +64 -0
- figrecipe/_editor/_templates/_styles/_buttons.py +206 -0
- figrecipe/_editor/_templates/_styles/_color_input.py +123 -0
- figrecipe/_editor/_templates/_styles/_controls.py +265 -0
- figrecipe/_editor/_templates/_styles/_dynamic_props.py +144 -0
- figrecipe/_editor/_templates/_styles/_forms.py +126 -0
- figrecipe/_editor/_templates/_styles/_hitmap.py +184 -0
- figrecipe/_editor/_templates/_styles/_inspector.py +90 -0
- figrecipe/_editor/_templates/_styles/_labels.py +118 -0
- figrecipe/_editor/_templates/_styles/_modals.py +98 -0
- figrecipe/_editor/_templates/_styles/_overlays.py +130 -0
- figrecipe/_editor/_templates/_styles/_preview.py +225 -0
- figrecipe/_editor/_templates/_styles/_selection.py +73 -0
- figrecipe/_params/_DECORATION_METHODS.py +33 -0
- figrecipe/_params/_PLOTTING_METHODS.py +58 -0
- figrecipe/_params/__init__.py +9 -0
- figrecipe/_recorder.py +92 -110
- figrecipe/_recorder_utils.py +124 -0
- figrecipe/_reproducer/__init__.py +18 -0
- figrecipe/_reproducer/_core.py +498 -0
- figrecipe/_reproducer/_custom_plots.py +279 -0
- figrecipe/_reproducer/_seaborn.py +100 -0
- figrecipe/_reproducer/_violin.py +186 -0
- figrecipe/_seaborn.py +14 -9
- figrecipe/_serializer.py +2 -2
- figrecipe/_signatures/README.md +68 -0
- figrecipe/_signatures/__init__.py +12 -2
- figrecipe/_signatures/_kwargs.py +273 -0
- figrecipe/_signatures/_loader.py +114 -57
- figrecipe/_signatures/_parsing.py +147 -0
- figrecipe/_utils/__init__.py +6 -4
- figrecipe/_utils/_crop.py +10 -4
- figrecipe/_utils/_image_diff.py +37 -33
- figrecipe/_utils/_numpy_io.py +0 -1
- figrecipe/_utils/_units.py +11 -3
- figrecipe/_validator.py +12 -3
- figrecipe/_wrappers/_axes.py +193 -170
- figrecipe/_wrappers/_axes_helpers.py +136 -0
- figrecipe/_wrappers/_axes_plots.py +418 -0
- figrecipe/_wrappers/_axes_seaborn.py +157 -0
- figrecipe/_wrappers/_figure.py +277 -18
- figrecipe/_wrappers/_panel_labels.py +127 -0
- figrecipe/_wrappers/_plot_helpers.py +143 -0
- figrecipe/_wrappers/_violin_helpers.py +180 -0
- figrecipe/plt.py +0 -1
- figrecipe/pyplot.py +2 -1
- figrecipe/styles/__init__.py +12 -11
- figrecipe/styles/_dotdict.py +72 -0
- figrecipe/styles/_finalize.py +134 -0
- figrecipe/styles/_fonts.py +77 -0
- figrecipe/styles/_kwargs_converter.py +178 -0
- figrecipe/styles/_plot_styles.py +209 -0
- figrecipe/styles/_style_applier.py +60 -202
- figrecipe/styles/_style_loader.py +73 -121
- figrecipe/styles/_themes.py +151 -0
- figrecipe/styles/presets/MATPLOTLIB.yaml +95 -0
- figrecipe/styles/presets/SCITEX.yaml +181 -0
- figrecipe-0.7.4.dist-info/METADATA +429 -0
- figrecipe-0.7.4.dist-info/RECORD +188 -0
- figrecipe/_reproducer.py +0 -358
- figrecipe-0.5.0.dist-info/METADATA +0 -336
- figrecipe-0.5.0.dist-info/RECORD +0 -26
- {figrecipe-0.5.0.dist-info → figrecipe-0.7.4.dist-info}/WHEEL +0 -0
- {figrecipe-0.5.0.dist-info → figrecipe-0.7.4.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
# -*- coding: utf-8 -*-
|
|
3
|
+
"""Preview panel CSS styles for the figure editor.
|
|
4
|
+
|
|
5
|
+
This module contains CSS for:
|
|
6
|
+
- Preview panel and header
|
|
7
|
+
- SciTeX branding
|
|
8
|
+
- File switcher
|
|
9
|
+
- Zoom controls
|
|
10
|
+
- Preview wrapper and checkerboard background
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
STYLES_PREVIEW = """
|
|
14
|
+
/* Preview Panel */
|
|
15
|
+
.preview-panel {
|
|
16
|
+
flex: 1;
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
border-right: 1px solid var(--border-color);
|
|
20
|
+
min-width: 400px;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.preview-header {
|
|
24
|
+
display: flex;
|
|
25
|
+
justify-content: space-between;
|
|
26
|
+
align-items: center;
|
|
27
|
+
padding: 12px 16px;
|
|
28
|
+
background: var(--bg-secondary);
|
|
29
|
+
border-bottom: 1px solid var(--border-color);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.preview-header h2 {
|
|
33
|
+
font-size: 16px;
|
|
34
|
+
font-weight: 600;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/* SciTeX branding */
|
|
38
|
+
.scitex-branding {
|
|
39
|
+
display: flex;
|
|
40
|
+
align-items: center;
|
|
41
|
+
gap: 8px;
|
|
42
|
+
text-decoration: none;
|
|
43
|
+
color: var(--text-primary);
|
|
44
|
+
transition: opacity 0.2s;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.scitex-branding:hover {
|
|
48
|
+
opacity: 0.8;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.scitex-icon {
|
|
52
|
+
width: 28px;
|
|
53
|
+
height: 28px;
|
|
54
|
+
border-radius: 4px;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.figrecipe-title {
|
|
58
|
+
font-size: 16px;
|
|
59
|
+
font-weight: 600;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/* File Switcher */
|
|
63
|
+
.file-switcher {
|
|
64
|
+
display: flex;
|
|
65
|
+
align-items: center;
|
|
66
|
+
gap: 6px;
|
|
67
|
+
margin-left: 16px;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.file-selector {
|
|
71
|
+
padding: 6px 10px;
|
|
72
|
+
font-size: 13px;
|
|
73
|
+
border: 1px solid var(--border-color);
|
|
74
|
+
border-radius: 4px;
|
|
75
|
+
background: var(--bg-primary);
|
|
76
|
+
color: var(--text-primary);
|
|
77
|
+
min-width: 180px;
|
|
78
|
+
max-width: 280px;
|
|
79
|
+
cursor: pointer;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.file-selector:hover {
|
|
83
|
+
border-color: var(--accent-color);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.file-selector:focus {
|
|
87
|
+
outline: none;
|
|
88
|
+
border-color: var(--accent-color);
|
|
89
|
+
box-shadow: 0 0 0 2px var(--selection-color);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.file-selector option {
|
|
93
|
+
padding: 4px 8px;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.file-selector option[data-current="true"] {
|
|
97
|
+
font-weight: bold;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.btn-new {
|
|
101
|
+
width: 28px;
|
|
102
|
+
height: 28px;
|
|
103
|
+
padding: 0;
|
|
104
|
+
font-size: 18px;
|
|
105
|
+
font-weight: bold;
|
|
106
|
+
border: 1px solid var(--border-color);
|
|
107
|
+
border-radius: 4px;
|
|
108
|
+
background: var(--bg-primary);
|
|
109
|
+
color: var(--text-primary);
|
|
110
|
+
cursor: pointer;
|
|
111
|
+
display: flex;
|
|
112
|
+
align-items: center;
|
|
113
|
+
justify-content: center;
|
|
114
|
+
transition: all 0.2s;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.btn-new:hover {
|
|
118
|
+
background: var(--accent-color);
|
|
119
|
+
color: white;
|
|
120
|
+
border-color: var(--accent-color);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.preview-controls {
|
|
124
|
+
display: flex;
|
|
125
|
+
gap: 12px;
|
|
126
|
+
align-items: center;
|
|
127
|
+
flex-wrap: wrap;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.zoom-controls {
|
|
131
|
+
display: flex;
|
|
132
|
+
align-items: center;
|
|
133
|
+
gap: 4px;
|
|
134
|
+
background: var(--bg-secondary);
|
|
135
|
+
border-radius: 4px;
|
|
136
|
+
padding: 2px 6px;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.zoom-controls button {
|
|
140
|
+
width: 28px;
|
|
141
|
+
height: 28px;
|
|
142
|
+
padding: 0;
|
|
143
|
+
font-size: 16px;
|
|
144
|
+
display: flex;
|
|
145
|
+
align-items: center;
|
|
146
|
+
justify-content: center;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.zoom-controls #zoom-level {
|
|
150
|
+
min-width: 45px;
|
|
151
|
+
text-align: center;
|
|
152
|
+
font-size: 12px;
|
|
153
|
+
font-weight: 500;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.preview-wrapper {
|
|
157
|
+
flex: 1;
|
|
158
|
+
display: flex;
|
|
159
|
+
align-items: center;
|
|
160
|
+
justify-content: center;
|
|
161
|
+
padding: 20px;
|
|
162
|
+
background: var(--bg-tertiary);
|
|
163
|
+
position: relative;
|
|
164
|
+
overflow: auto;
|
|
165
|
+
/* Checkerboard pattern for transparency */
|
|
166
|
+
background-image:
|
|
167
|
+
linear-gradient(45deg, #ccc 25%, transparent 25%),
|
|
168
|
+
linear-gradient(-45deg, #ccc 25%, transparent 25%),
|
|
169
|
+
linear-gradient(45deg, transparent 75%, #ccc 75%),
|
|
170
|
+
linear-gradient(-45deg, transparent 75%, #ccc 75%);
|
|
171
|
+
background-size: 20px 20px;
|
|
172
|
+
background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/* Dark checkerboard in dark mode */
|
|
176
|
+
[data-theme="dark"] .preview-wrapper {
|
|
177
|
+
background-color: #2a2a2a;
|
|
178
|
+
background-image:
|
|
179
|
+
linear-gradient(45deg, #333333 25%, transparent 25%),
|
|
180
|
+
linear-gradient(-45deg, #333333 25%, transparent 25%),
|
|
181
|
+
linear-gradient(45deg, transparent 75%, #333333 75%),
|
|
182
|
+
linear-gradient(-45deg, transparent 75%, #333333 75%);
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
#preview-image {
|
|
186
|
+
max-width: none;
|
|
187
|
+
max-height: none;
|
|
188
|
+
object-fit: contain;
|
|
189
|
+
cursor: crosshair;
|
|
190
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
|
|
191
|
+
position: relative;
|
|
192
|
+
z-index: 1;
|
|
193
|
+
transform-origin: center center;
|
|
194
|
+
transition: transform 0.1s ease-out;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
/* Zoom container for coordinated transform of image and overlays */
|
|
198
|
+
.zoom-container {
|
|
199
|
+
display: inline-block;
|
|
200
|
+
position: relative;
|
|
201
|
+
transform-origin: top left;
|
|
202
|
+
transition: transform 0.1s ease-out;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
/* Show grab cursor hint when zoomed in */
|
|
206
|
+
.preview-wrapper.zoomed-in {
|
|
207
|
+
cursor: grab;
|
|
208
|
+
/* Disable centering when zoomed to allow proper scrolling from top-left */
|
|
209
|
+
align-items: flex-start;
|
|
210
|
+
justify-content: flex-start;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
/* Pan cursor when dragging */
|
|
214
|
+
.preview-wrapper.panning {
|
|
215
|
+
cursor: grabbing !important;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.preview-wrapper.panning * {
|
|
219
|
+
cursor: grabbing !important;
|
|
220
|
+
}
|
|
221
|
+
"""
|
|
222
|
+
|
|
223
|
+
__all__ = ["STYLES_PREVIEW"]
|
|
224
|
+
|
|
225
|
+
# EOF
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
# -*- coding: utf-8 -*-
|
|
3
|
+
"""Selection overlay CSS styles for the figure editor.
|
|
4
|
+
|
|
5
|
+
This module contains CSS for:
|
|
6
|
+
- Selection overlay container
|
|
7
|
+
- Selection rectangles, polylines, circles
|
|
8
|
+
- Primary selection highlights
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
STYLES_SELECTION = """
|
|
12
|
+
/* Selection Overlay */
|
|
13
|
+
.selection-overlay {
|
|
14
|
+
position: absolute;
|
|
15
|
+
top: 0;
|
|
16
|
+
left: 0;
|
|
17
|
+
width: 100%;
|
|
18
|
+
height: 100%;
|
|
19
|
+
pointer-events: none;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.selection-rect {
|
|
23
|
+
--element-color: #2563eb; /* Default fallback to accent color */
|
|
24
|
+
fill: var(--element-color);
|
|
25
|
+
fill-opacity: 0.15;
|
|
26
|
+
stroke: var(--element-color);
|
|
27
|
+
stroke-opacity: 0.6;
|
|
28
|
+
stroke-width: 2;
|
|
29
|
+
stroke-dasharray: 5, 3;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/* Primary selection in a group - solid border */
|
|
33
|
+
.selection-rect.selection-primary {
|
|
34
|
+
fill-opacity: 0.2;
|
|
35
|
+
stroke-opacity: 0.8;
|
|
36
|
+
stroke-width: 3;
|
|
37
|
+
stroke-dasharray: none;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
/* Selection for lines - show stroke along the path */
|
|
41
|
+
.selection-polyline {
|
|
42
|
+
--element-color: #2563eb;
|
|
43
|
+
fill: none !important;
|
|
44
|
+
stroke: var(--element-color);
|
|
45
|
+
stroke-width: 8;
|
|
46
|
+
stroke-opacity: 0.5;
|
|
47
|
+
stroke-linecap: round;
|
|
48
|
+
stroke-linejoin: round;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/* Selection for scatter points */
|
|
52
|
+
.selection-circle {
|
|
53
|
+
--element-color: #2563eb;
|
|
54
|
+
fill: var(--element-color);
|
|
55
|
+
fill-opacity: 0.3;
|
|
56
|
+
stroke: var(--element-color);
|
|
57
|
+
stroke-opacity: 0.7;
|
|
58
|
+
stroke-width: 2;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/* Subtle selection for scatter points (less visually overwhelming) */
|
|
62
|
+
.selection-circle-subtle {
|
|
63
|
+
--element-color: #2563eb;
|
|
64
|
+
fill: none;
|
|
65
|
+
stroke: var(--element-color);
|
|
66
|
+
stroke-opacity: 0.4;
|
|
67
|
+
stroke-width: 1.5;
|
|
68
|
+
}
|
|
69
|
+
"""
|
|
70
|
+
|
|
71
|
+
__all__ = ["STYLES_SELECTION"]
|
|
72
|
+
|
|
73
|
+
# EOF
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
# -*- coding: utf-8 -*-
|
|
3
|
+
# Timestamp: "2025-12-23 09:55:04 (ywatanabe)"
|
|
4
|
+
# File: /home/ywatanabe/proj/figrecipe/src/figrecipe/DECORATION_METHODS.py
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
"""Top-level docstring here"""
|
|
8
|
+
|
|
9
|
+
DECORATION_METHODS = {
|
|
10
|
+
"set_xlabel",
|
|
11
|
+
"set_ylabel",
|
|
12
|
+
"set_title",
|
|
13
|
+
"set_xlim",
|
|
14
|
+
"set_ylim",
|
|
15
|
+
"set_aspect",
|
|
16
|
+
"legend",
|
|
17
|
+
"grid",
|
|
18
|
+
"axhline",
|
|
19
|
+
"axvline",
|
|
20
|
+
"axhspan",
|
|
21
|
+
"axvspan",
|
|
22
|
+
"text",
|
|
23
|
+
"annotate",
|
|
24
|
+
"clabel",
|
|
25
|
+
"axis", # For axis('off'), axis('on'), axis('equal'), etc.
|
|
26
|
+
"set_xticks",
|
|
27
|
+
"set_yticks",
|
|
28
|
+
"set_xticklabels",
|
|
29
|
+
"set_yticklabels",
|
|
30
|
+
"tick_params",
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
# EOF
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
# -*- coding: utf-8 -*-
|
|
3
|
+
# Timestamp: "2025-12-23 09:55:10 (ywatanabe)"
|
|
4
|
+
# File: /home/ywatanabe/proj/figrecipe/src/figrecipe/PLOTTING_METHODS.py
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
"""Top-level docstring here"""
|
|
8
|
+
|
|
9
|
+
PLOTTING_METHODS = {
|
|
10
|
+
"plot",
|
|
11
|
+
"scatter",
|
|
12
|
+
"bar",
|
|
13
|
+
"barh",
|
|
14
|
+
"hist",
|
|
15
|
+
"hist2d",
|
|
16
|
+
"boxplot",
|
|
17
|
+
"violinplot",
|
|
18
|
+
"pie",
|
|
19
|
+
"errorbar",
|
|
20
|
+
"fill",
|
|
21
|
+
"fill_between",
|
|
22
|
+
"fill_betweenx",
|
|
23
|
+
"stackplot",
|
|
24
|
+
"stem",
|
|
25
|
+
"step",
|
|
26
|
+
"imshow",
|
|
27
|
+
"pcolor",
|
|
28
|
+
"pcolormesh",
|
|
29
|
+
"contour",
|
|
30
|
+
"contourf",
|
|
31
|
+
"quiver",
|
|
32
|
+
"barbs",
|
|
33
|
+
"streamplot",
|
|
34
|
+
"hexbin",
|
|
35
|
+
"tripcolor",
|
|
36
|
+
"triplot",
|
|
37
|
+
"tricontour",
|
|
38
|
+
"tricontourf",
|
|
39
|
+
"eventplot",
|
|
40
|
+
"stairs",
|
|
41
|
+
"ecdf",
|
|
42
|
+
"matshow",
|
|
43
|
+
"spy",
|
|
44
|
+
"loglog",
|
|
45
|
+
"semilogx",
|
|
46
|
+
"semilogy",
|
|
47
|
+
"acorr",
|
|
48
|
+
"xcorr",
|
|
49
|
+
"specgram",
|
|
50
|
+
"psd",
|
|
51
|
+
"csd",
|
|
52
|
+
"cohere",
|
|
53
|
+
"angle_spectrum",
|
|
54
|
+
"magnitude_spectrum",
|
|
55
|
+
"phase_spectrum",
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
# EOF
|