Skip to content

Commit

Permalink
change float -> real in qml. (float is not a qml type)
Browse files Browse the repository at this point in the history
  • Loading branch information
adam-ce committed Nov 27, 2023
1 parent 1081b64 commit b025a71
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/Map.qml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Rectangle {
}

Rectangle {
function oc_scale() : float {
function oc_scale() : real {
if (renderer.camera_operation_centre_distance < 0) {
return 1.0;
}
Expand Down Expand Up @@ -71,12 +71,12 @@ Rectangle {
property int vertical_text_margin: 10
property real alpha_value: my_alpha()
visible: alpha_value > 0
function my_scale() : float {
function my_scale() : real {
let importance_scale = model.importance / 10;
let distance_scale = model.size + 0.3
return importance_scale * (importance_scale + 0.5) * distance_scale
}
function my_alpha() : float {
function my_alpha() : real {
let alpha = my_scale();
if (alpha < 0.37)
alpha = 0.0;
Expand Down

0 comments on commit b025a71

Please sign in to comment.