There have been some interesting changes in the last two weeks. The first of which is that I decided to change the name of my project ( repository ) to graPharo.
Next, I have been working on optimizing some layout algorithms. Equidistant circle and weighted circle have been implemented in many other projects, but the algorithms that were used, have not been working properly in every situation.
If we are talking about equidistant circle, the problem was found when we change the shape of vertices to rectangles or if vertices have different sizes. Than the positioning would not match the definition of equidistant ( to put all vertices on the circle in such a way, that they are equally distant from their neighbours).
In the original algorithm to calculate angle of separation and the gap, we used only each vertices height, which worked well if the width is absolutly the same. But since that is not the case, we had to find the way to recognize which dimension is needed from which vertex and then use that one in the calculation.
Similar problem was with weighted circle, to calculate the weight factor of a vertex, we would only use height. Which would make a mistake if the width of the vertex is bigger than the height. For this reason, in the optimized version, we choose bigger of two dimensions and use it to make the calculation.