1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-01-18 17:19:50 +00:00
Commit graph

2008 commits

Author SHA1 Message Date
OverloadedOrama a9ca858303 Use a new Layer class to handle layer information
This replaces the old Global.layers nested array mess, and makes the code easier to read and to understand.
2020-06-01 16:42:53 +03:00
OverloadedOrama 1762383c6b Use enum instead of strings for Global.theme_type
Another potential small performance boost when changing themes.
2020-06-01 03:36:07 +03:00
OverloadedOrama e1788a19ef Ignore warnings
I don't know what else to do about them, they seem trivial anyway
2020-06-01 03:11:00 +03:00
OverloadedOrama b17ec93dbb Remove draw_pixel(), use draw_pixel_blended() instead 2020-06-01 02:49:54 +03:00
OverloadedOrama c06999a57f Refactored DrawingAlgos.draw_brush(), made draw_pixel() method
This also fixes alpha blending and lighting/darkening issues when drawing pixels with mirroring.
2020-06-01 02:32:44 +03:00
OverloadedOrama 5246ce23ef Refactored Canvas.gd 2020-06-01 01:32:44 +03:00
OverloadedOrama 9b4956b4f1 Even more Global left/right variables became arrays
ColorAndToolOptions has now the same code for left and right tool options, with more similar refactoring coming soon to places like Canvas and DrawingAlgos
2020-06-01 00:44:53 +03:00
OverloadedOrama 15ef00bf46 Language and theme checkboxes are now radio buttons 2020-05-31 23:48:06 +03:00
OverloadedOrama 71fa2795b1 Added ItemList to themes 2020-05-31 23:43:24 +03:00
Kinwailo 69f08e90fd
Refactoring perferences dialog (#251) 2020-05-31 23:04:59 +03:00
OverloadedOrama 9c59dc1c88 Use Global.Mouse_Button instead of strings for comparison
This should be a slight increase in performance
2020-05-31 18:46:47 +03:00
OverloadedOrama 4cc0ccb97b More Global left/right variables became Arrays
Global.update_left_custom_brush() and its right counterpart have also now become Global.update_custom_brush(mouse_button : int)
2020-05-31 18:40:47 +03:00
OverloadedOrama c538140de2 Changed Global node variables to arrays for left/right
Instead of having 2 variables for left & right nodes, use an array instead. This will help with better looking code, automation and less repetitive code, as seen in ToolButtons.gd. Move related refactoring will follow.
2020-05-31 18:03:44 +03:00
OverloadedOrama 37a8ad2447 Fixed line making with Shift and don't let color picker pick colors outside of canvas 2020-05-31 16:24:08 +03:00
OverloadedOrama 5b7d161ecf Use enums instead of strings for tools
This could be a slight increase in performance
2020-05-31 16:04:33 +03:00
rob-a-bolton 145e3de7c4
Gimp palette import fixes. Support for newer format, and support for unnamed colours (#250) 2020-05-31 13:51:08 +03:00
OverloadedOrama bda9e6267d Drawing is no longer limited by the canvas boundaries
his means that, if you have a brush largen than 1px, you can draw on the edges of the canvas. All pixels that are being drawn outside of the canvas will still have no effect.
2020-05-31 01:07:08 +03:00
OverloadedOrama 4fc2888b68 Removed coord clamping from fill_gaps()
This should make line making behave as expected when the mouse is outside of canvas boundaries
2020-05-31 00:42:35 +03:00
Hugo Locurcio 9a1f5bf5b8
Remove fallback for OS.min_window_size now that Godot 3.2 is out (#249)
The latest Pixelorama versions require Godot 3.2 to run.
2020-05-31 00:20:41 +03:00
OverloadedOrama 7a509a2047 Moved draw_brush() and fill_gaps() from Canvas.gd to DrawingAlgos.gd
draw_brush() is currently very ugly and probably needs inside refactoring
2020-05-30 00:46:58 +03:00
OverloadedOrama c84c6a19d7 Renamed handle_running_pixelorama_with_arguments() to handle_loading_files()
handle_loading_files() is also used for _on_files_dropped()
2020-05-30 00:28:17 +03:00
OverloadedOrama ae89d3e291 Connected "files_dropped" signal to a method
This lets the user drag and drop files into Pixelorama, while it runs, to open them. This doesn't work properly and will crash when it can't open the files. It will get merged into master soon.
2020-05-29 20:19:22 +03:00
OverloadedOrama 00a0ab882a Created DrawingAlgos.gd and moved a lot of drawing code there
Moved code from Global.gd and Canvas.gd to DrawingAlgos.gd. Will also move the fill_gaps and draw_brush methods of Canvas.gd next. Maybe even refactor the inside of them a bit to make them easier to read.
2020-05-29 03:16:44 +03:00
OverloadedOrama a5e10631cd Moved shortcuts code from PreferencesDialog 2020-05-28 19:51:25 +03:00
OverloadedOrama 0e63860092 Split theme related code from PreferencesDialog into HandleThemes.gd 2020-05-28 03:49:14 +03:00
OverloadedOrama 379b574257 Split code from PreferencesDialog.gd to HandleLanguages.gd
Also moved PreferencesDialog script & scene to src/Preferences. More Preferences code splitting will follow.
2020-05-28 03:41:28 +03:00
OverloadedOrama ef89c650b2 Fixed TextureRect images of the circle brushes in BrushesPopup
They all had the pixel brush image in their TextureRect
2020-05-24 00:32:20 +03:00
Igor Santarek aae3ae0cf4
Refactoring Main.gd. Mostly cutting big methods into smaller ones. (#244)
* Refactoring Main.gd. Mostly cutting big methods into smaller one.

- Reduced size of _ready method in Main.gd
- Moved code from certain parts of old _ready method into seperate methods
- Fixed the translation bug related to CurrentFrame node in TopMenuContainer scene. The CurrentFrame node wasn't updating the language when I was changing language. I've also changed the translation file for this.
- Fixed Global.palette_option_button.selected related warning. Because of some unknown reasons, git didn't push completed line there.
- Moved code from file_menu_id_pressed and view_menu_id_pressed method in Main.gd to separate methods to make it more readable.

* Removed window_title changes from Main.tscn

Co-authored-by: OverloadedOrama <35376950+OverloadedOrama@users.noreply.github.com>
2020-05-24 00:22:06 +03:00
Igor Santarek 852e249143
Refactoring image_menu_id_pressed method in Main.gd (#243)
* Refactoring image_menu_id_pressed method in Main.gd

I've moved the code from each "match" case into a seperate method to make it more readable.

Co-authored-by: OverloadedOrama <35376950+OverloadedOrama@users.noreply.github.com>
2020-05-22 15:05:55 +03:00
OverloadedOrama 12c6118763 Created ToolButtons.gd, moved code from Main.gd there 2020-05-21 21:30:40 +03:00
OverloadedOrama 5f9c1976d2 Made BrushesPopup and PatternsPopup their own scenes 2020-05-21 20:37:20 +03:00
OverloadedOrama d2539f44f0 Removed brush_selected signal 2020-05-21 20:33:00 +03:00
OverloadedOrama 0629449bdf Created UI.tscn
All of the main UI elements are now in UI.tscn instead of Main.tscn
2020-05-21 20:21:01 +03:00
OverloadedOrama 55527501d0 Created TopMenuContainer.tscn and ViewportContainer.gd 2020-05-21 20:13:19 +03:00
OverloadedOrama 2190c21d9d Separated PalettePanelContainer from Main.tscn, made it its own scene
And put all 3 palette dialogs there instead of Main
2020-05-21 02:50:57 +03:00
OverloadedOrama 30e7b34dc9 Made OpenSprite and SaveSprite separate scenes 2020-05-20 01:44:27 +03:00
OverloadedOrama 8e6516a4d4 Use error dialog for 2 more cases
NoProjectEditedOrCreatedAlertDialog and OpenLastProjectAlertDialog
2020-05-20 01:37:36 +03:00
OverloadedOrama 2ebdf51047 Use error dialog instead of individual erro dialogs for when removing palettes 2020-05-20 01:31:38 +03:00
OverloadedOrama 8c2c8a1d7b Rebase master (remove palette) to refactoring 2020-05-20 01:02:25 +03:00
OverloadedOrama 1e114d6f4f Created ColorAndToolOptions script and scene
Removed the tool option signals from Main.gd and put them to ColorAndToolOptions.gd. Instead of having 2 methods for left and right, they are now in one method, using a boolean to differentiate between left and right.
2020-05-20 00:57:07 +03:00
OverloadedOrama c1db72865f Revert c02cda6b10
Left tool shortcuts get ignored completely if we change is_action_pressed to is_action_released.
2020-05-20 00:51:41 +03:00
Igor Santarek eb47d24df3
New remove current palette feature (#239)
* New remove current palette feature

This commit adds new feature to Pixelorama that will allow user to remove the current selected palette.

* Fixed grammar and added focus_mode = 0 on the remove palette button

Co-authored-by: OverloadedOrama <35376950+OverloadedOrama@users.noreply.github.com>
2020-05-20 00:35:48 +03:00
OverloadedOrama c879633f4b Change min value and step of autosave interval spinbox to 0.5 2020-05-18 16:53:38 +03:00
OverloadedOrama c02cda6b10 Made tool keyboard shortcuts fire on action release 2020-05-16 19:59:02 +03:00
OverloadedOrama d0825495d1 v0.7 - The Timeline Update! 2020-05-16 14:48:13 +03:00
Aaron Franke 7f3902be92
Update gitignore (#234) 2020-05-16 13:48:23 +03:00
OverloadedOrama 528b444101 Changed icon 2020-05-15 22:07:07 +03:00
OverloadedOrama ea52b7b129 Updated changelog link in Main.gd 2020-05-15 20:49:48 +03:00
OverloadedOrama a3ec615b0a Updated splash screen - Added Wishdream's art
Congratulations to Wishdream for being the winner of the first splash screen art contest in our Discord server.
2020-05-15 16:20:23 +03:00
OverloadedOrama ede68d7bf4 Made focus_mode = 0 for the tool buttons 2020-05-13 16:37:46 +03:00
OverloadedOrama 1740c11513 Made XDGDataPaths extend Reference
This could clear the "ObjectDB Instances still exist!" and "Resources Still in use at Exit!" errors when you exit Pixelorama.
2020-05-12 04:01:04 +03:00
OverloadedOrama 7361e01b1d Added forgotten translations, bumped version to rc3 and small dialog UI changes 2020-05-11 20:07:16 +03:00
OverloadedOrama 4a0ffd8cd4 Made "Crop Image" affect all frames 2020-05-11 18:41:41 +03:00
OverloadedOrama 74f3644e17 Made "Scale Image" affect all frames 2020-05-11 17:43:58 +03:00
OverloadedOrama 358a95f709 Changed CameraMovement.fit_to_frame() to get a Vector2 as an argument for the canvas size
This fixes the issue when importing an image, not as a new frame, that did not get fitted to frame.
2020-05-11 16:33:44 +03:00
OverloadedOrama 62a695366a Toggled autosave on by default, and open last project off by default 2020-05-11 16:15:59 +03:00
OverloadedOrama 5424472c95 Clear layers when importing an image that is not to be added as a new frame 2020-05-11 02:40:27 +03:00
OverloadedOrama d82aa339f8 Fixed crash when loading a .pxo file with less layers than the current project already had 2020-05-11 01:56:02 +03:00
OverloadedOrama cf1530d338 Fixed issue with color picker tool, picking the wrong color value
The color picker was picking color values left over from an undo operation. Meaning, if you drew something and then undid it, the color picker would pick the color before the undo.
2020-05-11 01:46:24 +03:00
OverloadedOrama b4ae097d14 Changed zoom fit to frame algorithm, again
Put the new code in a new fit_to_frame() method inside CameraMovement.gd. The old code did not work properly for images with width larger than their height.
2020-05-10 15:46:21 +03:00
OverloadedOrama 74c238b0f5 Added link to docs in the Help menu 2020-05-10 02:00:24 +03:00
OverloadedOrama e1142212fd Changed the way Pixelorama's version is being split when loading a .pxo file
The old way weren't causing any issues, but it would have caused with double-digit version numbers. Also fixed backwards compatibility issue with 0.6.2 and previous versions.
2020-05-09 22:58:09 +03:00
OverloadedOrama 7dbea9c0b0 Fixed stack overflow crash when the user set the loop mode to ping-pong and played the animation on a single frame with its own tag
The crash only occured when it was one frame in that tag, but there were also more frames in general. A very rare scenario.
2020-05-09 21:38:28 +03:00
OverloadedOrama 0e807c176f Fixed issue with splash screen buttons, not keeping the background modulation when opening another dialog 2020-05-09 15:54:43 +03:00
OverloadedOrama 0cd8fa7ddf Fixes critical bug with saving projects that contained linked cels
It used to save the linked cel array which contained the canvas nodes into the .pxo. This, however, does not make sense, because the canvas nodes are being recreated when a .pxo is loaded. Therefore, they are different nodes than they used to be.

Now, an array containing the frame numbers which have cels linked for each frame is being saved and loaded into the pxo.
2020-05-09 03:51:23 +03:00
John Jerome Romero adc109ed18
Added selective animation tag export for Spritesheets (#230)
* Added selective frame tag export for Spritesheets

* Changes LinesCount value and max_value to canvas_size

This does not allow the spritesheet to contain more frames than the tag has, because it limits its size to the number of frames the currently selected tag has.

Co-authored-by: Manolis Papadeas <35376950+OverloadedOrama@users.noreply.github.com>
2020-05-09 02:46:51 +03:00
OverloadedOrama 7484ce1b9e Added a Tween to make the background UI darker when a dialog is opened 2020-05-08 18:37:45 +03:00
OverloadedOrama 51b6aadbdd Makes the background UI darker when a dialog is being opened 2020-05-08 03:10:23 +03:00
OverloadedOrama 0f5c7c5e59 Updated donors in the About dialog 2020-05-07 17:02:35 +03:00
OverloadedOrama 896d7e4aeb Updated changelog URL in Main.gd 2020-05-06 22:45:09 +03:00
OverloadedOrama 1873945e9f Renamed Gold theme to Caramel 2020-05-06 22:01:58 +03:00
OverloadedOrama 0203a019c7 Set default clear color to be the same as the theme's PanelContainer bg_color 2020-05-06 20:51:56 +03:00
OverloadedOrama 85d438a9c4 Set the presets of CreateNewImage and FrameTagDialog color pickers to be invisible 2020-05-06 20:24:22 +03:00
OverloadedOrama 1be6662b75 Made PaletteImportFileDialog smaller 2020-05-06 19:41:21 +03:00
OverloadedOrama 85ffd389be Renamed "Godot" theme to Blue 2020-05-06 16:16:39 +03:00
OverloadedOrama 748171d4f2 Added tool textures for the blue theme 2020-05-06 15:56:44 +03:00
OverloadedOrama 55e7178e1f Changing a button's texturerect child no longer requires the theme in its file path
Instead, it automatically finds its path, adds the new file name and loads the new texture.
2020-05-06 15:19:53 +03:00
OverloadedOrama 9ce7bae2f9 Updated changelog in SplashDialog and made it a bit bigger 2020-05-06 02:21:42 +03:00
OverloadedOrama 3c39e28d72 Change selected frame label color based on theme 2020-05-06 01:36:14 +03:00
OverloadedOrama f99b486919 Made the fake grabber change texture based on theme & other small UI changes 2020-05-06 01:19:09 +03:00
OverloadedOrama c1602ad26a Big UI overhaul - added PanelContainers to group similar elements
Removed separators entirely. Also made the AnimationTimeline have a StyleBoxFlat of its own, which we use to expand its margin top to cover the little space left because of the VSplitContainer. We also use a TextureRect as a fake VSplitContainer grabber.
2020-05-06 00:55:17 +03:00
OverloadedOrama 7559756c50 Changed layer button and "current frame" text position
Made AboutDialog's min size a little bigger too
2020-05-05 21:50:39 +03:00
OverloadedOrama 6e2400e8fe Added missing autosave translations in Preferences 2020-05-05 16:03:32 +03:00
OverloadedOrama 61fab1a7de [BREAKS COMPATIBILITY WITH GODOT <=3.1.1] Implemented Indonesian & Czech languages
Pixelorama now requires at least Godot 3.1.2 or 3.2.x to work, because TranslationServer.get_loaded_locales() was not included in older versions. If you're using an older version of Godot, please update. Godot 3.2.1 is the currently recommended version, until 3.2.2 is out.

Also updated the list of the translators.
2020-05-05 14:45:16 +03:00
Manolis Papadeas 1ad1ecb960
Asset renaming (#225)
* Renamed the Asset folder and subfolders to lowercase

* Fixed font loading issue

Co-authored-by: OverloadedOrama <manoschool@yahoo.com>
2020-05-05 03:53:58 +03:00
OverloadedOrama a056a87492 Update PaletteButton.tscn
Changed mouse_default_cursor_shape to 2 (pointing hand)
2020-05-04 04:16:52 +03:00
OverloadedOrama 415db39e64 Changed tool TextureButtons into Buttons 2020-05-04 04:07:43 +03:00
OverloadedOrama 0ebc7a6033 Use dark theme's button textures for the gold theme 2020-05-04 02:38:41 +03:00
OverloadedOrama a4014e5842 Pixelorama's version number now appears on the window title 2020-05-04 00:04:00 +03:00
OverloadedOrama 8b682570b2 If we have cmdline_args, ensure the images are opened last
This way, cmdline_args loading overwrites load_last_project()
2020-05-03 21:45:05 +03:00
OverloadedOrama 991eb5a615 Export optimization
process_frame() was being called twice when the export dialog appeared, and the frame number was different than the one already stored in the export dialog
2020-05-03 19:19:12 +03:00
OverloadedOrama 4f1c475c8d Set export path when importing an image 2020-05-03 18:47:13 +03:00
OverloadedOrama 2b5f6b47ee Made the remove frame button get disabled when there's only one frame 2020-05-03 18:17:12 +03:00
OverloadedOrama 2ee4c541c9 Fixed tool texture loading 2020-05-03 13:39:20 +03:00
OverloadedOrama 28c4ee8f90 Saved the TransparentChecker shader as a resource
In case it gets used in other places too in the future, like preview backgrounds.
2020-05-03 03:49:44 +03:00
OverloadedOrama d8a1e5de12 Changed default colors for the checker background
Should be easier on the eye. For the dark themes, at least.
2020-05-03 03:42:44 +03:00
OverloadedOrama 563270bad7 Fixed play, onion skinning and loop button textures 2020-05-03 03:36:40 +03:00
OverloadedOrama 23865396e2 Changed default clear color for Godot theme 2020-05-03 03:15:47 +03:00
OverloadedOrama 9482b47825 Changed Palette and Layer TextureButtons into Buttons, massive asset renaming
Most asset filenames are now in snake_case
2020-05-03 03:13:08 +03:00
OverloadedOrama 148d918f12 Removed NotoSansCJKtc-Bold to save space
Updated some missing translations from SplashDialog too
2020-05-02 23:11:41 +03:00
OverloadedOrama babd5759f8 Makes sure that BackupConfirmation dialog is properly centered
Moved yield(get_tree().create_timer(0.01), "timeout") in _ready() of Main.gd outside of the if, to affect the BackupConfirmation dialog too.
2020-05-02 18:10:01 +03:00
OverloadedOrama b70fae36a3 Append Global.root_directory to XDG_DATA_DIRS
This lets Pixelorama to search for brushes, palettes & patterns in the "pixelorama" folder that may be on the root folder of the executable. Useful for non-package builds, like itch.io, and for the using Pixelorama inside the editor. It should not cause issues for packages but if it does, let me know.
2020-05-02 16:41:30 +03:00
OverloadedOrama 8005474446 Changed mouse_default_cursor_shapes in SplashDialog 2020-05-02 01:47:48 +03:00
OverloadedOrama fe7e984432 Filenames of assets in "Tool Cursors" are now in snake_case 2020-05-02 01:41:50 +03:00
OverloadedOrama 28de4d56f6 Added "icons" and "splash_screen" folders into Assets/Graphics
Moved all the relative assets there, including the icon files which no longer are on the res:// folder. The main page of the repository should look much cleaner now.
2020-05-02 01:34:55 +03:00
OverloadedOrama c35e4b0613 Created a "UI" folder in src
And a Timeline folder in UI
2020-05-02 01:19:01 +03:00
OverloadedOrama 8d5a673543 Moved "Themes & Styles" to "Assets/themes" 2020-05-02 00:59:34 +03:00
OverloadedOrama 646fc19a70 Merged "Scripts" and "Prefabs" folders into "src"
Made a new "src" folder that will contain the source code files, like all the GDScript and scene files. Please read this for more details: https://www.gdquest.com/docs/guidelines/best-practices/godot-gdscript/

It made no sense to keep scenes separate from their scripts. More file organizing will follow soon.
2020-05-01 22:17:05 +03:00