pgModeler 0.9.4-alpha is finally ready!
Multiple layers support, custom canvas colors and much more.

ATTENTION: the database model file structure has changed since the last stable 0.9.3. Models created in older releases will certainly fail to load due to incompatibilities because some attributes in the XML code don't exist anymore or have changed during the development of 0.9.4-alpha. Before loading your database models in this new release, please, make sure to have a backup of all of them and follow the steps presented by the model fix tool to correct the documents' structure. Not paying attention to this situation may cause irreversible data loss! If the fix procedures aren't enough to make your database models loadable again, please, ask for help at the official support channels!

These last five months have passed like a lightning (at least for me) and we finally have reached the next version of pgModeler, the one that opens a new development cycle and maybe the last one for the series 0.9.x. It's not a secret that I'm planning to start working on pgModeler 1.0 for a long time (since 2018 to be precise), but the circumstances of life have prevented me to step up this project to the next level. Anyway, I'll dedicate a new blog post to talk about pgModeler 1.0. So, talking specifically about pgModeler 0.9.4-alpha, I dedicated a lot of time to bring support for multiple layers while working on small improvements here and there that brought more stability and reliability to the tool.

Multiple layers support

The layers support, introduced by pgModeler 0.9.2-alpha, was intended to be used to separate objects in different contexts and quickly hide/display them. This feature was pretty simple and started to receive some suggestions for improvements. The main complaint about layers at that time was the lack of ability to visually identify in which layer an object was in. So, thinking of that situation, we have added the ability to put an object in two or more layers at once, and, additionally to that, pgModeler will now draw rectangles with custom colors around the objects that are part of a certain layer. Besides, we have also included the ability to change the color of the layer names to make this feature fully customizable. The complete result is in the right portion of the image below.

At the left portion of the above image, we have the improved widget that handles all the layers' settings. As you can see, now it's possible to toggle the displaying of layer rectangles and names around the objects, as well as to set up the colors of the elements of the layers. Like in previous versions, the checkboxes aside from the layers' names are used to quickly toggle the visibility of a specific layer. You can quickly toggle the visibility of all layers by clicking the button Visibility and activating the presented actions. In this release, it's also possible to rename the default layer which was not possible in previous versions.

The below image shows that in pgModeler 0.9.4-alpha you can quickly move objects to the desired layers. To do so, just select the graphical objects in the canvas area by using one of the several actions for that purpose, right-click the selection of the objects, and then focus the menu item Quick > Set layers. After that step, a floating listing will be presented where it's possible to define all the layers to where the objects will be placed on. One important thing to mention is that the layers that are common between the selected objects will be checked during the first display of the listing. The layers selection is automatically applied to the selected objects once the listing is hidden.

Metadata handling improvements

The metadata handling process was improved in order to support the new multiple layers feature. Now it's possible to transfer layers configurations from a model to another by checking the option Objects' layers configuration. Another enhancement done is the ability to merge duplicated textboxes, tags, and generic SQL objects through the option Merge duplicated objects. With the merging option, it's possible to make the mentioned objects kinds in the destination model (the one in which a set of metadata is being applied) to be forcibly replaced the ones presented in a metadata backup file or source database model.

Custom canvas colors

Thinking of user's eyes comfort, we've introduced the custom color for canvas elements like grid line colors, page delimiter line colors. The colors can be configured in the General settings at pgModeler's settings dialog. Once defined the desired color just click Apply so they can be applied to all loaded models. This small improvement is the starting of a series of UI/UX enhancements I'm planning to do to pgModeler so it can be more pleasant to use (in the sense of comfort). Another improvement on the way is the ability to set up custom colors for source code elements so the users can match their system color pattern to pgModeler's color pattern in its different GUI elements.

New attributes for function and procedure

Functions and procedures received support for parallelism settings available since PostgreSQL 9.6 through the attribute PARALLEL SAFE | UNSAFE | RESTRICTED. Another advance in these objects is the support for transform types which list the transforms that must be applied to the function or procedure during an execution. Finally, attending to some old requests, we've added the support for runtime configuration parameters for functions and procedures through SET configuration_parameter = value in these objects' DDL command.


There were other fixes and improvements done to this release. In addition to the multiple layers support, pgModeler will now use a compatibility routine when loading models created in previous versions (0.9.3 and below) in order to avoid losing information about layers and active layers. The database model loading process was also fixed in such a way so the changelog used during diff process is correctly retrieved from XML code.

In order to reflect the multiple layers support for older models the pgModeler's command-line interface will now rename the attribute layer to layers so they can be properly adjusted to 0.9.4-alpha. Attending to some requests the minimum size of the main window was adjusted to 640x480 so it can fit on smaller screens avoiding blocking access to some UI components that could prevent the proper usage of the tool.

The option Truncate before alter columns in the diff process was removed since its use is discouraged and dangerous in some situations due to the risk of dropping objects that aren't expected to be removed. There were some minor fixes in the database import feature including the table importing in order to avoid setting up a partitioning strategy when the table is not a partitioned one. Another fix in reverse engineering is the correct update to the model layers information before adding it to the main window avoiding importing a database in which all objects are hidden since no layer was marked as active.

There were important fixes in the SQL code generation in such a way to avoid malformed code for triggers and functions based on internal language. The codebase was patched in several portions in order to build in all supported Qt versions, mainly the oldest one 5.9.x. Finally, the complete list of changes of this version is available in the file

That's it! As usual, I hope you all enjoy another result of my dedication to this project. Don't forget to let your thoughts in the comments sections and if you need any support to make this release work don't hesitate to ask for help at the GitHub issues page of this project.

Until next time. Stay safe! ;)

Comments (0) Add a comment

Add new comment

  • 0/1024