Coverage for paintmaskanimator/_canvas_members.py: 100%
4 statements
« prev ^ index » next coverage.py v7.17.0, created at 2026-11-02 04:50 +0000
« prev ^ index » next coverage.py v7.17.0, created at 2026-11-02 04:50 +0000
1"""Type-only member declarations shared across the canvas mixins.
3This module exists purely to give pyright/pylance the attributes, methods and
4signals really provided at runtime by the composed ``PaintCanvas`` class (and its Qt
5base). Each mixin lives in its own file, so a checker inspecting one mixin in
6isolation cannot see members defined on its siblings or set in
7``PaintCanvas.__init__``; without these stubs every such access was reported as
8``reportAttributeAccessIssue``.
10At runtime ``CanvasMembers`` is an empty ``object`` subclass, so mixing it in
11is harmless. Under ``TYPE_CHECKING`` it inherits the real Qt base, so Qt
12methods resolve too. A genuinely undefined name -- a typo or a removed
13attribute -- still surfaces, because it never appears in this list.
15Entries are being migrated from ``Any`` to their real types; every one that
16moves off ``Any`` starts type-checking its own call sites, so prefer adding a
17precise type here over widening one. ``Any`` remains the default for the many
18method stubs, whose signatures live with the mixin that defines them.
19"""
20from __future__ import annotations
22from typing import TYPE_CHECKING, Any
24if TYPE_CHECKING:
25 from PySide6.QtWidgets import QWidget
26 from PySide6.QtCore import Signal
27 from .document import Document
28 from .models import Frame, Layer
29 from .undo_entries import TransformUndo, UndoEntry
30 _MembersBase = QWidget
31else:
32 _MembersBase = object
34class CanvasMembers(_MembersBase):
35 if TYPE_CHECKING:
36 def _record_transform_history(self, before: TransformUndo) -> None: ...
38 _exposure_index: Any
39 _exposure_index_signature: Any
40 preview_color_remap: dict
41 _brush_resize_anchor: tuple[float, float] | None
42 cellChanged: Signal
43 changed: Signal
44 clipAnimationDropped: Signal
45 colorSampled: Signal
46 colorUsed: Signal
47 imagesDropped: Signal
48 onionInteractionChanged: Signal
49 onionInteractionFinished: Signal
50 projectDropped: Signal
51 selectionChanged: Signal
52 selectionCleared: Signal
53 status_message: Signal
54 timeRemapDropped: Signal
55 viewChanged: Signal
56 _active_mesh_cols: Any
57 _active_mesh_rows: Any
58 _active_tool_panel: Any
59 _advance_stabilized_brush: Any
60 _begin_onion_interaction_drag: Any
61 _begin_opaque_brush_stroke: Any
62 _binary_paint_overlay_rgba: Any
63 _blend_overlay_into_active_layer: Any
64 _bool_mask_image: Any
65 _brush_blended_colors: Any
66 _brush_cursor_inside: Any
67 _brush_cursor_widget_pos: Any
68 _brush_follow_settle: Any
69 _brush_follow_timer: Any
70 _brush_runtime_warmed: Any
71 _brush_stabilizer_history: Any
72 _brush_stabilizer_window: Any
73 _brush_started_with_content: Any
74 _build_playback_key_map: Any
75 _build_tp_geometry_cache: Any
76 _build_tp_label_image: Any
77 _cell_structure_dirty: Any
78 _clear_selection_state: Any
79 _clear_timeline_layer_cell: Any
80 _clear_tp_transform_masks: Any
81 _cleared_selection_base: Any
82 _color_filter_cache: Any
83 _color_index_cache: Any
84 _current_stroke_color: Any
85 _curved_mesh_points: Any
86 _display_layer_image: Any
87 _layer_display_source: Any
88 _document: Document
89 _draw_onion_range: Any
90 _draw_stabilized_brush_to: Any
91 _draw_tapered_path: Any
92 _emit_actual_paint_colors: Any
93 _ensure_before_region: Any
94 _ensure_frame_count: Any
95 _eyedropper_cursor: Any
96 _eyedropper_preview_ns: int
97 _eyedropper_sample_pixel: tuple[int, int] | None
98 _finish_opaque_brush_stroke: Any
99 _finish_stabilized_brush: Any
100 _hue_cluster_palette_from_samples: Any
101 _invalidate_tp_preview_cache: Any
102 _last_brush_pressure: Any
103 _last_raw_canvas: Any
104 _right_eyedropper_drag: bool
105 _line_palette_labels: Any
106 _line_preview_path: Any
107 _local_color_variation: Any
108 _make_white_transparent: Any
109 _masked_selection_source: Any
110 _median_cut_palette_from_samples: Any
111 _mesh_catmull_scalar: Any
112 _mesh_curve_point: Any
113 _mesh_preview_image: Any
114 _mesh_reference_grid: Any
115 _merge_quality_transform: Any
116 _natural_path_key: Any
117 _normalized_angle: Any
118 _onion_cache: Any
119 _onion_frame_identity: Any
120 _onion_frame_indices: Any
121 _onion_interaction_axis: Any
122 _onion_interaction_direction: Any
123 _onion_interaction_dragging: Any
124 _onion_interaction_mode: Any
125 _onion_interaction_operation: Any
126 _onion_interaction_start_next: Any
127 _onion_interaction_start_next_rotation: Any
128 _onion_interaction_start_next_scale: Any
129 _onion_interaction_start_pan: Any
130 _onion_interaction_start_previous: Any
131 _onion_interaction_start_previous_rotation: Any
132 _onion_interaction_start_previous_scale: Any
133 _onion_interaction_start_tu_tb_scale: Any
134 _onion_interaction_start_view_rotation: Any
135 _onion_interaction_start_widget: Any
136 _onion_widget_delta_to_canvas: Any
137 _paint_rgb_palette: Any
138 _pil_l_to_qimage: Any
139 _pil_rgba_to_qimage: Any
140 _place_imported_image: Any
141 _playback_active: Any
142 _playback_cache_dimensions: Any
143 _playback_cache_limit: Any
144 _playback_frame_cache: Any
145 _playback_resolved_keys: Any
146 playback_range_start: int
147 playback_range_end: int | None
148 _position_selection_clear_overlay: Any
149 _prepare_draw_painter: Any
150 _prepare_tp_transform_masks: Any
151 _pressure_input_history: Any
152 _priority_palette_colors_from_samples: Any
153 _project_transform_source: Any
154 _proxy_transform_preview_image: Any
155 _qimage_gray_array: Any
156 _qimage_rgba_array: Any
157 _qimage_to_pil_rgba: Any
158 _quad_homography: Any
159 _read_image_file: Any
160 _regular_grid_points: Any
161 _regular_mesh_reference_points: Any
162 _render_deferred_transform_line_preview: Any
163 _reset_brush_stabilizer: Any
164 _reset_selection_transform: Any
165 _rgb_hsv_features: Any
166 _rgba_array_to_qimage: Any
167 _rotated_vector: Any
168 _scanline_connected_region: Any
169 _selection_blink_timer: Any
170 _selection_fade_opacity: Any
171 _selection_fade_started: Any
172 _selection_source_from_image: Any
173 _sequence_archive: Any
174 _sequence_source_bank: Any
175 _sequence_source_bank_layer_index: Any
176 _sequence_source_bank_layer_name: Any
177 _shape_path: Any
178 _shape_rect: Any
179 _shift_timeline_layer_left: Any
180 _shift_timeline_layer_right: Any
181 _silhouette_cache: Any
182 _view_preview_cache: Any
183 _smooth_brush_pressure: Any
184 _snap_overlay_to_exact_rgbs: Any
185 _stabilized_brush_point: Any
186 _stabilized_canvas: Any
187 _start_brush_follow_timer: Any
188 _stop_brush_follow_timer: Any
189 _stroke_before_region: Any
190 _stroke_before_tiles: Any
191 _stroke_dirty_rect: Any
192 _stroke_prev_has_content: Any
193 _stroke_undo_frame: Any
194 _stroke_undo_layer: Any
195 _surface_guided_palette_labels: Any
196 _tinted_onion_image: Any
197 _tp_geometry_cache_bbox: Any
198 _tp_geometry_cache_fill_overlay: Any
199 _tp_geometry_cache_is_current: Any
200 _tp_geometry_cache_key: Any
201 _tp_geometry_cache_line_soft: Any
202 _tp_geometry_key: Any
203 _tp_inverse_mapper: Any
204 _tp_label_colors: Any
205 _tp_label_image: Any
206 _tp_mask_key: Any
207 _tp_mask_preview_image: Any
208 _tp_mask_source_key: Any
209 _tp_prepare_palette_image: Any
210 _tp_preview_cache_image: Any
211 _tp_preview_cache_key: Any
212 _tp_preview_progress_busy: Any
213 _tp_preview_progress_scheduled: Any
214 _tp_proxy_rendering: Any
215 _tp_proxy_source_image: Any
216 _tp_proxy_source_key: Any
217 _tp_transform_bbox: Any
218 _tp_transparent_to_white: Any
219 _tp_uses_proxy: Any
220 _tp_white_to_transparent: Any
221 _transform_is_reducing: Any
222 _transform_line_adjusting: Any
223 _transform_line_preview_timer: Any
224 _trim_unused_trailing_frames: Any
225 _update_onion_interaction_drag: Any
226 _update_selection_clear_overlay: Any
227 _update_selection_fade: Any
228 _update_stroke_region: Any
229 active_layer: Any
230 active_layer_index: int
231 add_frame: Any
232 add_layer: Any
233 apply_color_reduction_palette: Any
234 apply_mesh_release: Any
235 apply_selection_clip: Any
236 apply_sequence_only_entries: Any
237 apply_tone_curve: Any
238 apply_undo_entry: Any
239 auto_select_region: Any
240 auto_select_used_area: Any
241 background_mask_rgb: Any
242 begin_onion_canvas_position_interaction: Any
243 begin_onion_shift_interaction: Any
244 begin_onion_transform_interaction: Any
245 begin_selection_transform: Any
246 begin_transform_drag: Any
247 begin_transform_line_adjustment: Any
248 binarize_alpha_for_pixel_art: Any
249 brush_stabilizer_strength: Any
250 fill_opacity: Any
251 build_color_reduction_palette: Any
252 cancel_mesh: Any
253 cancel_onion_interaction: Any
254 cancel_selection_transform: Any
255 canvas_rect: Any
256 canvas_to_widget: Any
257 checker_dark: Any
258 checker_light: Any
259 clamped_index: Any
260 clear_selection: Any
261 clear_selection_preserving_used_colors: Any
262 coalesce_numbered_images: Any
263 link_layer_tracks: Any
264 color: Any
265 color_mode: Any
266 commit_line_tool: Any
267 _begin_brush_straight_line: Any
268 commit_mesh: Any
269 commit_selection_transform: Any
270 commit_shape_tool: Any
271 composite: Any
272 copy_selection: Any
273 create_blank_key: Any
274 current_exposure: Any
275 current_frame: int
276 current_state_for: Any
277 cut_selection: Any
278 delete_frame: Any
279 delete_layer: Any
280 delete_sequence_entry: Any
281 detect_opaque_border_background: Any
282 dilate: Any
283 displacement_at: Any
284 document_snapshot: Any
285 draw_frame_direct: Any
286 draw_line: Any
287 drawing: Any
288 effective_tool: Any
289 end_transform_drag: Any
290 ensure_editable_key: Any
291 erode: Any
292 estimate_mixed_boundary_pixels: Any
293 fill_lasso_polygon: Any
294 filtered_layer_image: Any
295 _color_index_for_image: Any
296 finish_transform_line_adjustment: Any
297 flip_active_layer: Any
298 flip_horizontal: bool
299 flip_vertical: bool
300 flood_fill: Any
301 frames: list[Frame]
302 image_alpha_statistics: Any
303 import_image: Any
304 import_image_sequence: Any
305 init_mesh: Any
306 insert_sequence_blank: Any
307 inside: Any
308 is_pseudo_transparent_color: Any
309 lasso: Any
310 last_canvas: Any
311 last_widget: Any
312 layers: list[Layer]
313 line_control: Any
314 line_curve_stage: Any
315 line_end: Any
316 line_start: Any
317 main_color: Any
318 mask_all_enabled: Any
319 mask_color_rgb: Any
320 mask_color_rgbs: Any
321 mesh_active: Any
322 mesh_grid: Any
323 mesh_original: Any
324 mesh_points: Any
325 middle_hand: Any
326 move_sequence_image: Any
327 move_timeline_cell: Any
328 nearest_mesh: Any
329 nearest_transform_handle: Any
330 next_frame: Any
331 next_key_frame: Any
332 normalize_sequence_numbers: Any
333 sequence_number_normalization: Any
334 normalize_tone_curve_points: Any
335 onion_all_layers: Any
336 onion_center_percent: Any
337 onion_next_color: Any
338 onion_next_color_enabled: Any
339 onion_next_count: Any
340 onion_next_levels: Any
341 onion_next_opacity: Any
342 onion_next_rotation: Any
343 onion_next_scale: Any
344 onion_next_shift_x: Any
345 onion_next_shift_y: Any
346 onion_previous_color: Any
347 onion_previous_color_enabled: Any
348 onion_previous_count: Any
349 onion_previous_levels: Any
350 onion_previous_opacity: Any
351 onion_previous_rotation: Any
352 onion_previous_scale: Any
353 onion_previous_shift_x: Any
354 onion_previous_shift_y: Any
355 onion_selected_colors_only: Any
356 onion_shift_values: Any
357 onion_skin: Any
358 onion_transform_values: Any
359 onion_tu_tb_scale: Any
360 opaque_paint_color: Any
361 opaque_rgb_color_count: Any
362 paint_source_color: Any
363 pan: Any
364 paste_clipboard: Any
365 pen_size: Any
366 playback_advance: Any
367 playback_frame_image: Any
368 pressure_curve: Any
369 pressure_curve_points: Any
370 pressure_enabled: Any
371 pressure_max: Any
372 pressure_min: Any
373 pressure_size_scale: Any
374 pressure_value: Any
375 previous_frame: Any
376 previous_key_frame: Any
377 push_doc_undo: Any
378 push_layer_region_undo: Any
379 push_layer_undo: Any
380 push_undo: Any
381 raster_triangle: Any
382 rect_end: Any
383 rect_start: Any
384 redo: Any
385 redo_stack: list[UndoEntry]
386 history_branches: Any
387 clear_history_branches: Any
388 switch_history_branch: Any
389 refresh_quality_preview_with_counter: Any
390 report: Any
391 request_quality_preview_counter: Any
392 resolve_exposure_block: Any
393 resolve_key_frame: Any
394 rotate_selection_transform: Any
395 rotation: Any
396 sample: Any
397 sample_color: Any
398 select_exposure: Any
399 selected_mask_colors: Any
400 selected_used_color_rgbs: Any
401 selected_used_colors: Any
402 selection_bounds: Any
403 set_selection_mask: Any
404 set_zoom_around_canvas_center: Any
405 set_zoom_around_widget_point: Any
406 center_canvas: Any
407 selection_clear_overlay: Any
408 selection_mask_bool: Any
409 selection_mask_override: Any
410 selection_mask_rect: Any
411 selection_outline_polygons: Any
412 selection_polygon: Any
413 sequence_entry_columns: Any
414 set_brush_stabilizer: Any
415 set_duration: Any
416 set_layer_opacity: Any
417 set_layer_visibility: Any
418 set_onion_canvas_view_rotation: Any
419 set_pen_size: Any
420 set_playback_active: Any
421 set_tool: Any
422 set_transform_line_colors: Any
423 set_transform_line_threshold: Any
424 set_transform_mesh_grid: Any
425 set_transform_quality: Any
426 shape_end: Any
427 shape_start: Any
428 silhouette_layer_image: Any
429 view_layer_image: Any
430 view_preview: Any
431 silhouette_non_background: Any
432 show_initial_state: Any
433 stroke_before: Any
434 sub_color: Any
435 sync_numbered_image_from_cell: Any
436 temp_tool: Any
437 timeline_block_at: Any
438 timeline_mode: Any
439 timeline_step_columns: Any
440 tone_curve_lut: Any
441 tone_curve_samples: Any
442 tool: Any
443 transform_active: Any
444 transform_apply_all_frames: Any
445 transform_center: Any
446 transform_drag_kind: Any
447 transform_drag_points: Any
448 transform_drag_start: Any
449 transform_frame_index: Any
450 transform_handle: Any
451 transform_layer_index: Any
452 transform_line_threshold: Any
453 transform_mesh_cols: Any
454 transform_mesh_grid: Any
455 transform_mesh_reference_points: Any
456 transform_mesh_rows: Any
457 transform_mode: Any
458 transform_original_has_content: Any
459 transform_original_layer: Any
460 transform_outer_polygon: Any
461 transform_points: Any
462 transform_preview_image: Any
463 transform_quality: Any
464 transform_quality_active: Any
465 transform_rotation_handle: Any
466 transform_source: Any
467 transform_source_rect: Any
468 transform_tp_line_colors: Any
469 transform_tp_line_masks: Any
470 transform_tp_masks: Any
471 transform_tp_palette: Any
472 transform_tp_prepared_preview: Any
473 transformed_selection_outline: Any
474 transparent_display_color: Any
475 tween_pending: Any
476 undo: Any
477 undo_stack: list[UndoEntry]
478 update_tool_cursor: Any
479 update_transform_drag: Any
480 visible_color_rgbs: Any
481 warm_up_brush_runtime: Any
482 widget_to_canvas: Any
483 work_rect: Any
484 zoom: Any
485 _bucket_all_frames_enabled: Any
486 _bucket_tools: Any
487 _bucket_failure_message: Any
488 _fill_patch: Any
489 _layer_fill_pixels: Any
490 bucket_reference_pixels: Any
491 _bucket_reference_image: Any
492 _seed_in_bounds: Any
493 abort_skewer_fill: Any
494 accept_skewer_guess: Any
495 skewer_fill_has_guess: Any
496 bucket_options: Any
497 flood_fill_over_frames: Any
498 skewer_fill_pending: Any
499 skip_skewer_fill_frame: Any
500 skip_skewer_fill_direction: Any
501 _bucket_drag: Any
502 begin_bucket_drag: Any
503 continue_bucket_drag: Any
504 finish_bucket_drag: Any