mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 13:20:06 +00:00 
			
		
		
		
	
						commit
						ea19de3e5f
					
				
					 26 changed files with 851 additions and 483 deletions
				
			
		|  | @ -14,6 +14,7 @@ layout (location = 3) in vec4  aModulate; | ||||||
| layout (location = 4) in float aAngleDeg; | layout (location = 4) in float aAngleDeg; | ||||||
| layout (location = 5) in int   aThreshold; | layout (location = 5) in int   aThreshold; | ||||||
| layout (location = 6) in ivec2 aTimeRange; | layout (location = 6) in ivec2 aTimeRange; | ||||||
|  | layout (location = 7) in int   aDisplayed; | ||||||
| 
 | 
 | ||||||
| uniform mat4 uMVPMatrix; | uniform mat4 uMVPMatrix; | ||||||
| uniform mat4 uMapMatrix; | uniform mat4 uMapMatrix; | ||||||
|  | @ -42,8 +43,8 @@ vec2 latLngToScreenCoordinate(in vec2 latLng) | ||||||
| 
 | 
 | ||||||
| void main() | void main() | ||||||
| { | { | ||||||
|    // Always set displayed to true |    // Pass displayed to the geometry shader | ||||||
|    vsOut.displayed = 1; |    vsOut.displayed = aDisplayed; | ||||||
| 
 | 
 | ||||||
|    // Pass the threshold and time range to the geometry shader |    // Pass the threshold and time range to the geometry shader | ||||||
|    vsOut.threshold = aThreshold; |    vsOut.threshold = aThreshold; | ||||||
|  |  | ||||||
							
								
								
									
										
											BIN
										
									
								
								scwx-qt/res/textures/images/cursor-17.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								scwx-qt/res/textures/images/cursor-17.png
									
										
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 624 B | 
							
								
								
									
										
											BIN
										
									
								
								scwx-qt/res/textures/images/dot-3.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								scwx-qt/res/textures/images/dot-3.png
									
										
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							| After Width: | Height: | Size: 551 B | 
|  | @ -70,7 +70,9 @@ | ||||||
|         <file>res/palettes/wct/ZDR.pal</file> |         <file>res/palettes/wct/ZDR.pal</file> | ||||||
|         <file>res/textures/lines/default-1x7.png</file> |         <file>res/textures/lines/default-1x7.png</file> | ||||||
|         <file>res/textures/lines/test-pattern.png</file> |         <file>res/textures/lines/test-pattern.png</file> | ||||||
|  |         <file>res/textures/images/cursor-17.png</file> | ||||||
|         <file>res/textures/images/crosshairs-24.png</file> |         <file>res/textures/images/crosshairs-24.png</file> | ||||||
|  |         <file>res/textures/images/dot-3.png</file> | ||||||
|         <file>res/textures/images/mapbox-logo.svg</file> |         <file>res/textures/images/mapbox-logo.svg</file> | ||||||
|         <file>res/textures/images/maptiler-logo.svg</file> |         <file>res/textures/images/maptiler-logo.svg</file> | ||||||
|     </qresource> |     </qresource> | ||||||
|  |  | ||||||
|  | @ -8,6 +8,7 @@ | ||||||
| #include <execution> | #include <execution> | ||||||
| 
 | 
 | ||||||
| #include <boost/unordered/unordered_flat_map.hpp> | #include <boost/unordered/unordered_flat_map.hpp> | ||||||
|  | #include <boost/unordered/unordered_flat_set.hpp> | ||||||
| 
 | 
 | ||||||
| namespace scwx | namespace scwx | ||||||
| { | { | ||||||
|  | @ -32,8 +33,10 @@ static constexpr std::size_t kIconBufferLength = | ||||||
| static constexpr std::size_t kTextureBufferLength = | static constexpr std::size_t kTextureBufferLength = | ||||||
|    kNumTriangles * kVerticesPerTriangle * kPointsPerTexCoord; |    kNumTriangles * kVerticesPerTriangle * kPointsPerTexCoord; | ||||||
| 
 | 
 | ||||||
| // Threshold, start time, end time
 | // Threshold, start time, end time, displayed
 | ||||||
| static constexpr std::size_t kIntegersPerVertex_ = 3; | static constexpr std::size_t kIntegersPerVertex_ = 4; | ||||||
|  | static constexpr std::size_t kIntegerBufferLength_ = | ||||||
|  |    kNumTriangles * kVerticesPerTriangle * kIntegersPerVertex_; | ||||||
| 
 | 
 | ||||||
| struct GeoIconDrawItem | struct GeoIconDrawItem | ||||||
| { | { | ||||||
|  | @ -42,6 +45,7 @@ struct GeoIconDrawItem | ||||||
|    std::chrono::sys_time<std::chrono::seconds> endTime_ {}; |    std::chrono::sys_time<std::chrono::seconds> endTime_ {}; | ||||||
| 
 | 
 | ||||||
|    boost::gil::rgba32f_pixel_t modulate_ {1.0f, 1.0f, 1.0f, 1.0f}; |    boost::gil::rgba32f_pixel_t modulate_ {1.0f, 1.0f, 1.0f, 1.0f}; | ||||||
|  |    bool                        visible_ {true}; | ||||||
|    double                      latitude_ {}; |    double                      latitude_ {}; | ||||||
|    double                      longitude_ {}; |    double                      longitude_ {}; | ||||||
|    double                      x_ {}; |    double                      x_ {}; | ||||||
|  | @ -50,6 +54,8 @@ struct GeoIconDrawItem | ||||||
|    std::string                 iconSheet_ {}; |    std::string                 iconSheet_ {}; | ||||||
|    std::size_t                 iconIndex_ {}; |    std::size_t                 iconIndex_ {}; | ||||||
|    std::string                 hoverText_ {}; |    std::string                 hoverText_ {}; | ||||||
|  | 
 | ||||||
|  |    std::shared_ptr<types::IconInfo> iconInfo_ {}; | ||||||
| }; | }; | ||||||
| 
 | 
 | ||||||
| class GeoIcons::Impl | class GeoIcons::Impl | ||||||
|  | @ -82,9 +88,15 @@ public: | ||||||
| 
 | 
 | ||||||
|    ~Impl() {} |    ~Impl() {} | ||||||
| 
 | 
 | ||||||
|    void UpdateBuffers(); |    void        UpdateBuffers(); | ||||||
|    void UpdateTextureBuffer(); |    static void UpdateSingleBuffer(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|    void Update(bool textureAtlasChanged); |                                   std::size_t                  iconIndex, | ||||||
|  |                                   std::vector<float>&          iconBuffer, | ||||||
|  |                                   std::vector<GLint>&          integerBuffer, | ||||||
|  |                                   std::vector<IconHoverEntry>& hoverIcons); | ||||||
|  |    void        UpdateTextureBuffer(); | ||||||
|  |    void        UpdateModifiedIconBuffers(); | ||||||
|  |    void        Update(bool textureAtlasChanged); | ||||||
| 
 | 
 | ||||||
|    std::shared_ptr<GlContext> context_; |    std::shared_ptr<GlContext> context_; | ||||||
| 
 | 
 | ||||||
|  | @ -93,13 +105,16 @@ public: | ||||||
|    bool thresholded_ {false}; |    bool thresholded_ {false}; | ||||||
|    bool lastTextureAtlasChanged_ {false}; |    bool lastTextureAtlasChanged_ {false}; | ||||||
| 
 | 
 | ||||||
|  |    boost::unordered_flat_set<std::shared_ptr<GeoIconDrawItem>> dirtyIcons_ {}; | ||||||
|  | 
 | ||||||
|    std::chrono::system_clock::time_point selectedTime_ {}; |    std::chrono::system_clock::time_point selectedTime_ {}; | ||||||
| 
 | 
 | ||||||
|    std::mutex iconMutex_; |    std::mutex iconMutex_; | ||||||
| 
 | 
 | ||||||
|    boost::unordered_flat_map<std::string, types::IconInfo> |    boost::unordered_flat_map<std::string, std::shared_ptr<types::IconInfo>> | ||||||
|       currentIconSheets_ {}; |       currentIconSheets_ {}; | ||||||
|    boost::unordered_flat_map<std::string, types::IconInfo> newIconSheets_ {}; |    boost::unordered_flat_map<std::string, std::shared_ptr<types::IconInfo>> | ||||||
|  |       newIconSheets_ {}; | ||||||
| 
 | 
 | ||||||
|    std::vector<std::shared_ptr<GeoIconDrawItem>> currentIconList_ {}; |    std::vector<std::shared_ptr<GeoIconDrawItem>> currentIconList_ {}; | ||||||
|    std::vector<std::shared_ptr<GeoIconDrawItem>> newIconList_ {}; |    std::vector<std::shared_ptr<GeoIconDrawItem>> newIconList_ {}; | ||||||
|  | @ -240,6 +255,15 @@ void GeoIcons::Initialize() | ||||||
|                              reinterpret_cast<void*>(1 * sizeof(GLint))); |                              reinterpret_cast<void*>(1 * sizeof(GLint))); | ||||||
|    gl.glEnableVertexAttribArray(6); |    gl.glEnableVertexAttribArray(6); | ||||||
| 
 | 
 | ||||||
|  |    // aDisplayed
 | ||||||
|  |    gl.glVertexAttribPointer(7, | ||||||
|  |                             1, | ||||||
|  |                             GL_INT, | ||||||
|  |                             GL_FALSE, | ||||||
|  |                             kIntegersPerVertex_ * sizeof(GLint), | ||||||
|  |                             reinterpret_cast<void*>(3 * sizeof(float))); | ||||||
|  |    gl.glEnableVertexAttribArray(7); | ||||||
|  | 
 | ||||||
|    p->dirty_ = true; |    p->dirty_ = true; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | @ -338,10 +362,11 @@ void GeoIcons::AddIconSheet(const std::string& name, | ||||||
|                             std::int32_t       hotY) |                             std::int32_t       hotY) | ||||||
| { | { | ||||||
|    // Populate icon sheet map
 |    // Populate icon sheet map
 | ||||||
|    p->newIconSheets_.emplace(std::piecewise_construct, |    p->newIconSheets_.emplace( | ||||||
|                              std::tuple {name}, |       std::piecewise_construct, | ||||||
|                              std::forward_as_tuple(types::IconInfo { |       std::tuple {name}, | ||||||
|                                 name, iconWidth, iconHeight, hotX, hotY})); |       std::forward_as_tuple(std::make_shared<types::IconInfo>( | ||||||
|  |          name, iconWidth, iconHeight, hotX, hotY))); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::FinishIconSheets() | void GeoIcons::FinishIconSheets() | ||||||
|  | @ -349,7 +374,7 @@ void GeoIcons::FinishIconSheets() | ||||||
|    // Update icon sheets
 |    // Update icon sheets
 | ||||||
|    for (auto& iconSheet : p->newIconSheets_) |    for (auto& iconSheet : p->newIconSheets_) | ||||||
|    { |    { | ||||||
|       iconSheet.second.UpdateTextureInfo(); |       iconSheet.second->UpdateTextureInfo(); | ||||||
|    } |    } | ||||||
| 
 | 
 | ||||||
|    std::unique_lock lock {p->iconMutex_}; |    std::unique_lock lock {p->iconMutex_}; | ||||||
|  | @ -379,12 +404,26 @@ std::shared_ptr<GeoIconDrawItem> GeoIcons::AddIcon() | ||||||
|    return p->newIconList_.emplace_back(std::make_shared<GeoIconDrawItem>()); |    return p->newIconList_.emplace_back(std::make_shared<GeoIconDrawItem>()); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | void GeoIcons::SetIconVisible(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|  |                               bool                                    visible) | ||||||
|  | { | ||||||
|  |    if (di->visible_ != visible) | ||||||
|  |    { | ||||||
|  |       di->visible_ = visible; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
|  | } | ||||||
|  | 
 | ||||||
| void GeoIcons::SetIconTexture(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconTexture(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                               const std::string&                      iconSheet, |                               const std::string&                      iconSheet, | ||||||
|                               std::size_t                             iconIndex) |                               std::size_t                             iconIndex) | ||||||
| { | { | ||||||
|    di->iconSheet_ = iconSheet; |    if (di->iconSheet_ != iconSheet || di->iconIndex_ != iconIndex) | ||||||
|    di->iconIndex_ = iconIndex; |    { | ||||||
|  |       di->iconSheet_ = iconSheet; | ||||||
|  |       di->iconIndex_ = iconIndex; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|  | @ -393,10 +432,16 @@ void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                double                        xOffset, |                                double                        xOffset, | ||||||
|                                double                        yOffset) |                                double                        yOffset) | ||||||
| { | { | ||||||
|    di->latitude_  = latitude.value(); |    if (di->latitude_ != latitude.value() || | ||||||
|    di->longitude_ = longitude.value(); |        di->longitude_ != longitude.value() || di->x_ != xOffset || | ||||||
|    di->x_         = xOffset; |        di->y_ != yOffset) | ||||||
|    di->y_         = yOffset; |    { | ||||||
|  |       di->latitude_  = latitude.value(); | ||||||
|  |       di->longitude_ = longitude.value(); | ||||||
|  |       di->x_         = xOffset; | ||||||
|  |       di->y_         = yOffset; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|  | @ -405,37 +450,63 @@ void GeoIcons::SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                double xOffset, |                                double xOffset, | ||||||
|                                double yOffset) |                                double yOffset) | ||||||
| { | { | ||||||
|    di->latitude_  = latitude; |    if (di->latitude_ != latitude || di->longitude_ != longitude || | ||||||
|    di->longitude_ = longitude; |        di->x_ != xOffset || di->y_ != yOffset) | ||||||
|    di->x_         = xOffset; |    { | ||||||
|    di->y_         = yOffset; |       di->latitude_  = latitude; | ||||||
|  |       di->longitude_ = longitude; | ||||||
|  |       di->x_         = xOffset; | ||||||
|  |       di->y_         = yOffset; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconAngle(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconAngle(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                             units::angle::degrees<double>           angle) |                             units::angle::degrees<double>           angle) | ||||||
| { | { | ||||||
|    di->angle_ = angle; |    if (di->angle_ != angle) | ||||||
|  |    { | ||||||
|  |       di->angle_ = angle; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                boost::gil::rgba8_pixel_t               modulate) |                                boost::gil::rgba8_pixel_t               modulate) | ||||||
| { | { | ||||||
|    di->modulate_ = {modulate[0] / 255.0f, |    boost::gil::rgba32f_pixel_t newModulate = {modulate[0] / 255.0f, | ||||||
|                     modulate[1] / 255.0f, |                                               modulate[1] / 255.0f, | ||||||
|                     modulate[2] / 255.0f, |                                               modulate[2] / 255.0f, | ||||||
|                     modulate[3] / 255.0f}; |                                               modulate[3] / 255.0f}; | ||||||
|  | 
 | ||||||
|  |    if (di->modulate_ != newModulate) | ||||||
|  |    { | ||||||
|  |       di->modulate_ = {modulate[0] / 255.0f, | ||||||
|  |                        modulate[1] / 255.0f, | ||||||
|  |                        modulate[2] / 255.0f, | ||||||
|  |                        modulate[3] / 255.0f}; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                boost::gil::rgba32f_pixel_t             modulate) |                                boost::gil::rgba32f_pixel_t             modulate) | ||||||
| { | { | ||||||
|    di->modulate_ = modulate; |    if (di->modulate_ != modulate) | ||||||
|  |    { | ||||||
|  |       di->modulate_ = modulate; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::SetIconHoverText(const std::shared_ptr<GeoIconDrawItem>& di, | void GeoIcons::SetIconHoverText(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                 const std::string&                      text) |                                 const std::string&                      text) | ||||||
| { | { | ||||||
|    di->hoverText_ = text; |    if (di->hoverText_ != text) | ||||||
|  |    { | ||||||
|  |       di->hoverText_ = text; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void GeoIcons::FinishIcons() | void GeoIcons::FinishIcons() | ||||||
|  | @ -482,10 +553,11 @@ void GeoIcons::Impl::UpdateBuffers() | ||||||
|          continue; |          continue; | ||||||
|       } |       } | ||||||
| 
 | 
 | ||||||
|       auto& icon = it->second; |       auto& icon    = it->second; | ||||||
|  |       di->iconInfo_ = icon; | ||||||
| 
 | 
 | ||||||
|       // Validate icon
 |       // Validate icon
 | ||||||
|       if (di->iconIndex_ >= icon.numIcons_) |       if (di->iconIndex_ >= icon->numIcons_) | ||||||
|       { |       { | ||||||
|          // No icon found
 |          // No icon found
 | ||||||
|          logger_->warn("Invalid icon index: {}", di->iconIndex_); |          logger_->warn("Invalid icon index: {}", di->iconIndex_); | ||||||
|  | @ -495,101 +567,162 @@ void GeoIcons::Impl::UpdateBuffers() | ||||||
|       // Icon is valid, add to valid icon list
 |       // Icon is valid, add to valid icon list
 | ||||||
|       newValidIconList_.push_back(di); |       newValidIconList_.push_back(di); | ||||||
| 
 | 
 | ||||||
|       // Threshold value
 |       // Update icon buffer
 | ||||||
|       units::length::nautical_miles<double> threshold = di->threshold_; |       UpdateSingleBuffer(di, | ||||||
|       GLint thresholdValue = static_cast<GLint>(std::round(threshold.value())); |                          newValidIconList_.size() - 1, | ||||||
|  |                          newIconBuffer_, | ||||||
|  |                          newIntegerBuffer_, | ||||||
|  |                          newHoverIcons_); | ||||||
|  |    } | ||||||
| 
 | 
 | ||||||
|       // Start and end time
 |    // All icons have been updated
 | ||||||
|       GLint startTime = |    dirtyIcons_.clear(); | ||||||
|          static_cast<GLint>(std::chrono::duration_cast<std::chrono::minutes>( | } | ||||||
|                                di->startTime_.time_since_epoch()) |  | ||||||
|                                .count()); |  | ||||||
|       GLint endTime = |  | ||||||
|          static_cast<GLint>(std::chrono::duration_cast<std::chrono::minutes>( |  | ||||||
|                                di->endTime_.time_since_epoch()) |  | ||||||
|                                .count()); |  | ||||||
| 
 | 
 | ||||||
|       // Latitude and longitude coordinates in degrees
 | void GeoIcons::Impl::UpdateSingleBuffer( | ||||||
|       const float lat = static_cast<float>(di->latitude_); |    const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|       const float lon = static_cast<float>(di->longitude_); |    std::size_t                             iconIndex, | ||||||
|  |    std::vector<float>&                     iconBuffer, | ||||||
|  |    std::vector<GLint>&                     integerBuffer, | ||||||
|  |    std::vector<IconHoverEntry>&            hoverIcons) | ||||||
|  | { | ||||||
|  |    auto& icon = di->iconInfo_; | ||||||
| 
 | 
 | ||||||
|       // Base X/Y offsets in pixels
 |    // Threshold value
 | ||||||
|       const float x = static_cast<float>(di->x_); |    units::length::nautical_miles<double> threshold = di->threshold_; | ||||||
|       const float y = static_cast<float>(di->y_); |    GLint thresholdValue = static_cast<GLint>(std::round(threshold.value())); | ||||||
| 
 | 
 | ||||||
|       // Icon size
 |    // Start and end time
 | ||||||
|       const float iw = static_cast<float>(icon.iconWidth_); |    GLint startTime = | ||||||
|       const float ih = static_cast<float>(icon.iconHeight_); |       static_cast<GLint>(std::chrono::duration_cast<std::chrono::minutes>( | ||||||
|  |                             di->startTime_.time_since_epoch()) | ||||||
|  |                             .count()); | ||||||
|  |    GLint endTime = | ||||||
|  |       static_cast<GLint>(std::chrono::duration_cast<std::chrono::minutes>( | ||||||
|  |                             di->endTime_.time_since_epoch()) | ||||||
|  |                             .count()); | ||||||
| 
 | 
 | ||||||
|       // Hot X/Y (zero-based icon center)
 |    // Latitude and longitude coordinates in degrees
 | ||||||
|       const float hx = static_cast<float>(icon.hotX_); |    const float lat = static_cast<float>(di->latitude_); | ||||||
|       const float hy = static_cast<float>(icon.hotY_); |    const float lon = static_cast<float>(di->longitude_); | ||||||
| 
 | 
 | ||||||
|       // Final X/Y offsets in pixels
 |    // Base X/Y offsets in pixels
 | ||||||
|       const float lx = std::roundf(x - hx); |    const float x = static_cast<float>(di->x_); | ||||||
|       const float rx = std::roundf(lx + iw); |    const float y = static_cast<float>(di->y_); | ||||||
|       const float ty = std::roundf(y + hy); |  | ||||||
|       const float by = std::roundf(ty - ih); |  | ||||||
| 
 | 
 | ||||||
|       // Angle in degrees
 |    // Icon size
 | ||||||
|       units::angle::degrees<float> angle = di->angle_; |    const float iw = static_cast<float>(icon->iconWidth_); | ||||||
|       const float                  a     = angle.value(); |    const float ih = static_cast<float>(icon->iconHeight_); | ||||||
| 
 | 
 | ||||||
|       // Modulate color
 |    // Hot X/Y (zero-based icon center)
 | ||||||
|       const float mc0 = di->modulate_[0]; |    const float hx = static_cast<float>(icon->hotX_); | ||||||
|       const float mc1 = di->modulate_[1]; |    const float hy = static_cast<float>(icon->hotY_); | ||||||
|       const float mc2 = di->modulate_[2]; |  | ||||||
|       const float mc3 = di->modulate_[3]; |  | ||||||
| 
 | 
 | ||||||
|       newIconBuffer_.insert(newIconBuffer_.end(), |    // Final X/Y offsets in pixels
 | ||||||
|                             { |    const float lx = std::roundf(x - hx); | ||||||
|                                // Icon
 |    const float rx = std::roundf(lx + iw); | ||||||
|                                lat, lon, lx, by, mc0, mc1, mc2, mc3, a, // BL
 |    const float ty = std::roundf(y + hy); | ||||||
|                                lat, lon, lx, ty, mc0, mc1, mc2, mc3, a, // TL
 |    const float by = std::roundf(ty - ih); | ||||||
|                                lat, lon, rx, by, mc0, mc1, mc2, mc3, a, // BR
 |  | ||||||
|                                lat, lon, rx, by, mc0, mc1, mc2, mc3, a, // BR
 |  | ||||||
|                                lat, lon, rx, ty, mc0, mc1, mc2, mc3, a, // TR
 |  | ||||||
|                                lat, lon, lx, ty, mc0, mc1, mc2, mc3, a  // TL
 |  | ||||||
|                             }); |  | ||||||
|       newIntegerBuffer_.insert(newIntegerBuffer_.end(), |  | ||||||
|                                {thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime, |  | ||||||
|                                 thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime, |  | ||||||
|                                 thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime, |  | ||||||
|                                 thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime, |  | ||||||
|                                 thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime, |  | ||||||
|                                 thresholdValue, |  | ||||||
|                                 startTime, |  | ||||||
|                                 endTime}); |  | ||||||
| 
 | 
 | ||||||
|       if (!di->hoverText_.empty()) |    // Angle in degrees
 | ||||||
|  |    units::angle::degrees<float> angle = di->angle_; | ||||||
|  |    const float                  a     = angle.value(); | ||||||
|  | 
 | ||||||
|  |    // Modulate color
 | ||||||
|  |    const float mc0 = di->modulate_[0]; | ||||||
|  |    const float mc1 = di->modulate_[1]; | ||||||
|  |    const float mc2 = di->modulate_[2]; | ||||||
|  |    const float mc3 = di->modulate_[3]; | ||||||
|  | 
 | ||||||
|  |    // Visibility
 | ||||||
|  |    const GLint v = static_cast<GLint>(di->visible_); | ||||||
|  | 
 | ||||||
|  |    // Icon initialize list data
 | ||||||
|  |    const auto iconData = { | ||||||
|  |       // Icon
 | ||||||
|  |       lat, lon, lx, by, mc0, mc1, mc2, mc3, a, // BL
 | ||||||
|  |       lat, lon, lx, ty, mc0, mc1, mc2, mc3, a, // TL
 | ||||||
|  |       lat, lon, rx, by, mc0, mc1, mc2, mc3, a, // BR
 | ||||||
|  |       lat, lon, rx, by, mc0, mc1, mc2, mc3, a, // BR
 | ||||||
|  |       lat, lon, rx, ty, mc0, mc1, mc2, mc3, a, // TR
 | ||||||
|  |       lat, lon, lx, ty, mc0, mc1, mc2, mc3, a  // TL
 | ||||||
|  |    }; | ||||||
|  |    const auto integerData = {thresholdValue, startTime, endTime, v, | ||||||
|  |                              thresholdValue, startTime, endTime, v, | ||||||
|  |                              thresholdValue, startTime, endTime, v, | ||||||
|  |                              thresholdValue, startTime, endTime, v, | ||||||
|  |                              thresholdValue, startTime, endTime, v, | ||||||
|  |                              thresholdValue, startTime, endTime, v}; | ||||||
|  | 
 | ||||||
|  |    // Buffer position data
 | ||||||
|  |    auto iconBufferPosition = iconBuffer.end(); | ||||||
|  |    auto iconBufferOffset   = iconIndex * kIconBufferLength; | ||||||
|  | 
 | ||||||
|  |    auto integerBufferPosition = integerBuffer.end(); | ||||||
|  |    auto integerBufferOffset   = iconIndex * kIntegerBufferLength_; | ||||||
|  | 
 | ||||||
|  |    if (iconBufferOffset < iconBuffer.size()) | ||||||
|  |    { | ||||||
|  |       iconBufferPosition = iconBuffer.begin() + iconBufferOffset; | ||||||
|  |    } | ||||||
|  |    if (integerBufferOffset < integerBuffer.size()) | ||||||
|  |    { | ||||||
|  |       integerBufferPosition = integerBuffer.begin() + integerBufferOffset; | ||||||
|  |    } | ||||||
|  | 
 | ||||||
|  |    if (iconBufferPosition == iconBuffer.cend()) | ||||||
|  |    { | ||||||
|  |       iconBuffer.insert(iconBufferPosition, iconData); | ||||||
|  |    } | ||||||
|  |    else | ||||||
|  |    { | ||||||
|  |       std::copy(iconData.begin(), iconData.end(), iconBufferPosition); | ||||||
|  |    } | ||||||
|  | 
 | ||||||
|  |    if (integerBufferPosition == integerBuffer.cend()) | ||||||
|  |    { | ||||||
|  |       integerBuffer.insert(integerBufferPosition, integerData); | ||||||
|  |    } | ||||||
|  |    else | ||||||
|  |    { | ||||||
|  |       std::copy(integerData.begin(), integerData.end(), integerBufferPosition); | ||||||
|  |    } | ||||||
|  | 
 | ||||||
|  |    auto hoverIt = std::find_if(hoverIcons.begin(), | ||||||
|  |                                hoverIcons.end(), | ||||||
|  |                                [&di](auto& entry) { return entry.di_ == di; }); | ||||||
|  | 
 | ||||||
|  |    if (di->visible_ && !di->hoverText_.empty()) | ||||||
|  |    { | ||||||
|  |       const units::angle::radians<double> radians = angle; | ||||||
|  | 
 | ||||||
|  |       const auto sc = util::maplibre::LatLongToScreenCoordinate({lat, lon}); | ||||||
|  | 
 | ||||||
|  |       const float cosAngle = cosf(static_cast<float>(radians.value())); | ||||||
|  |       const float sinAngle = sinf(static_cast<float>(radians.value())); | ||||||
|  | 
 | ||||||
|  |       const glm::mat2 rotate {cosAngle, -sinAngle, sinAngle, cosAngle}; | ||||||
|  | 
 | ||||||
|  |       const glm::vec2 otl = rotate * glm::vec2 {lx, ty}; | ||||||
|  |       const glm::vec2 otr = rotate * glm::vec2 {rx, ty}; | ||||||
|  |       const glm::vec2 obl = rotate * glm::vec2 {lx, by}; | ||||||
|  |       const glm::vec2 obr = rotate * glm::vec2 {rx, by}; | ||||||
|  | 
 | ||||||
|  |       if (hoverIt == hoverIcons.end()) | ||||||
|       { |       { | ||||||
|          const units::angle::radians<double> radians = angle; |          hoverIcons.emplace_back(IconHoverEntry {di, sc, otl, otr, obl, obr}); | ||||||
| 
 |  | ||||||
|          const auto sc = util::maplibre::LatLongToScreenCoordinate({lat, lon}); |  | ||||||
| 
 |  | ||||||
|          const float cosAngle = cosf(static_cast<float>(radians.value())); |  | ||||||
|          const float sinAngle = sinf(static_cast<float>(radians.value())); |  | ||||||
| 
 |  | ||||||
|          const glm::mat2 rotate {cosAngle, -sinAngle, sinAngle, cosAngle}; |  | ||||||
| 
 |  | ||||||
|          const glm::vec2 otl = rotate * glm::vec2 {lx, ty}; |  | ||||||
|          const glm::vec2 otr = rotate * glm::vec2 {rx, ty}; |  | ||||||
|          const glm::vec2 obl = rotate * glm::vec2 {lx, by}; |  | ||||||
|          const glm::vec2 obr = rotate * glm::vec2 {rx, by}; |  | ||||||
| 
 |  | ||||||
|          newHoverIcons_.emplace_back( |  | ||||||
|             IconHoverEntry {di, sc, otl, otr, obl, obr}); |  | ||||||
|       } |       } | ||||||
|  |       else | ||||||
|  |       { | ||||||
|  |          hoverIt->otl_ = otl; | ||||||
|  |          hoverIt->otr_ = otr; | ||||||
|  |          hoverIt->obl_ = obl; | ||||||
|  |          hoverIt->obr_ = obr; | ||||||
|  |       } | ||||||
|  |    } | ||||||
|  |    else if (hoverIt != hoverIcons.end()) | ||||||
|  |    { | ||||||
|  |       hoverIcons.erase(hoverIt); | ||||||
|    } |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | @ -627,7 +760,7 @@ void GeoIcons::Impl::UpdateTextureBuffer() | ||||||
|       auto& icon = it->second; |       auto& icon = it->second; | ||||||
| 
 | 
 | ||||||
|       // Validate icon
 |       // Validate icon
 | ||||||
|       if (di->iconIndex_ >= icon.numIcons_) |       if (di->iconIndex_ >= icon->numIcons_) | ||||||
|       { |       { | ||||||
|          // No icon found
 |          // No icon found
 | ||||||
|          logger_->error("Invalid icon index: {}", di->iconIndex_); |          logger_->error("Invalid icon index: {}", di->iconIndex_); | ||||||
|  | @ -653,17 +786,17 @@ void GeoIcons::Impl::UpdateTextureBuffer() | ||||||
|       } |       } | ||||||
| 
 | 
 | ||||||
|       // Texture coordinates
 |       // Texture coordinates
 | ||||||
|       const std::size_t iconRow    = (di->iconIndex_) / icon.columns_; |       const std::size_t iconRow    = (di->iconIndex_) / icon->columns_; | ||||||
|       const std::size_t iconColumn = (di->iconIndex_) % icon.columns_; |       const std::size_t iconColumn = (di->iconIndex_) % icon->columns_; | ||||||
| 
 | 
 | ||||||
|       const float iconX = iconColumn * icon.scaledWidth_; |       const float iconX = iconColumn * icon->scaledWidth_; | ||||||
|       const float iconY = iconRow * icon.scaledHeight_; |       const float iconY = iconRow * icon->scaledHeight_; | ||||||
| 
 | 
 | ||||||
|       const float ls = icon.texture_.sLeft_ + iconX; |       const float ls = icon->texture_.sLeft_ + iconX; | ||||||
|       const float rs = ls + icon.scaledWidth_; |       const float rs = ls + icon->scaledWidth_; | ||||||
|       const float tt = icon.texture_.tTop_ + iconY; |       const float tt = icon->texture_.tTop_ + iconY; | ||||||
|       const float bt = tt + icon.scaledHeight_; |       const float bt = tt + icon->scaledHeight_; | ||||||
|       const float r  = static_cast<float>(icon.texture_.layerId_); |       const float r  = static_cast<float>(icon->texture_.layerId_); | ||||||
| 
 | 
 | ||||||
|       // clang-format off
 |       // clang-format off
 | ||||||
|       textureBuffer_.insert( |       textureBuffer_.insert( | ||||||
|  | @ -681,17 +814,51 @@ void GeoIcons::Impl::UpdateTextureBuffer() | ||||||
|    } |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | void GeoIcons::Impl::UpdateModifiedIconBuffers() | ||||||
|  | { | ||||||
|  |    // Update buffers for modified icons
 | ||||||
|  |    for (auto& di : dirtyIcons_) | ||||||
|  |    { | ||||||
|  |       // Find modified icon in the current list
 | ||||||
|  |       auto it = | ||||||
|  |          std::find(currentIconList_.cbegin(), currentIconList_.cend(), di); | ||||||
|  | 
 | ||||||
|  |       // Ignore invalid icons
 | ||||||
|  |       if (it == currentIconList_.cend()) | ||||||
|  |       { | ||||||
|  |          continue; | ||||||
|  |       } | ||||||
|  | 
 | ||||||
|  |       auto iconIndex = std::distance(currentIconList_.cbegin(), it); | ||||||
|  | 
 | ||||||
|  |       UpdateSingleBuffer(di, | ||||||
|  |                          iconIndex, | ||||||
|  |                          currentIconBuffer_, | ||||||
|  |                          currentIntegerBuffer_, | ||||||
|  |                          currentHoverIcons_); | ||||||
|  |    } | ||||||
|  | 
 | ||||||
|  |    // Clear list of modified icons
 | ||||||
|  |    if (!dirtyIcons_.empty()) | ||||||
|  |    { | ||||||
|  |       dirtyIcons_.clear(); | ||||||
|  |       dirty_ = true; | ||||||
|  |    } | ||||||
|  | } | ||||||
|  | 
 | ||||||
| void GeoIcons::Impl::Update(bool textureAtlasChanged) | void GeoIcons::Impl::Update(bool textureAtlasChanged) | ||||||
| { | { | ||||||
|    gl::OpenGLFunctions& gl = context_->gl(); |    gl::OpenGLFunctions& gl = context_->gl(); | ||||||
| 
 | 
 | ||||||
|  |    UpdateModifiedIconBuffers(); | ||||||
|  | 
 | ||||||
|    // If the texture atlas has changed
 |    // If the texture atlas has changed
 | ||||||
|    if (dirty_ || textureAtlasChanged || lastTextureAtlasChanged_) |    if (dirty_ || textureAtlasChanged || lastTextureAtlasChanged_) | ||||||
|    { |    { | ||||||
|       // Update texture coordinates
 |       // Update texture coordinates
 | ||||||
|       for (auto& iconSheet : currentIconSheets_) |       for (auto& iconSheet : currentIconSheets_) | ||||||
|       { |       { | ||||||
|          iconSheet.second.UpdateTextureInfo(); |          iconSheet.second->UpdateTextureInfo(); | ||||||
|       } |       } | ||||||
| 
 | 
 | ||||||
|       // Update OpenGL texture buffer data
 |       // Update OpenGL texture buffer data
 | ||||||
|  |  | ||||||
|  | @ -94,6 +94,13 @@ public: | ||||||
|     */ |     */ | ||||||
|    std::shared_ptr<GeoIconDrawItem> AddIcon(); |    std::shared_ptr<GeoIconDrawItem> AddIcon(); | ||||||
| 
 | 
 | ||||||
|  |    /**
 | ||||||
|  |     * @param [in] di Geo icon draw item | ||||||
|  |     * @param [in] visible Visibility of the icon | ||||||
|  |     */ | ||||||
|  |    void SetIconVisible(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|  |                        bool                                    visible); | ||||||
|  | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the texture of a geo icon. |     * Sets the texture of a geo icon. | ||||||
|     * |     * | ||||||
|  | @ -101,9 +108,9 @@ public: | ||||||
|     * @param [in] iconSheet The name of the icon sheet in the texture atlas |     * @param [in] iconSheet The name of the icon sheet in the texture atlas | ||||||
|     * @param [in] iconIndex The zero-based index of the icon in the icon sheet |     * @param [in] iconIndex The zero-based index of the icon in the icon sheet | ||||||
|     */ |     */ | ||||||
|    static void SetIconTexture(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconTexture(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                               const std::string&                      iconSheet, |                        const std::string&                      iconSheet, | ||||||
|                               std::size_t iconIndex); |                        std::size_t                             iconIndex); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the location of a geo icon. |     * Sets the location of a geo icon. | ||||||
|  | @ -114,11 +121,11 @@ public: | ||||||
|     * @param [in] xOffset The x-offset of the geo icon in pixels. Default is 0. |     * @param [in] xOffset The x-offset of the geo icon in pixels. Default is 0. | ||||||
|     * @param [in] yOffset The y-offset of the geo icon in pixels. Default is 0. |     * @param [in] yOffset The y-offset of the geo icon in pixels. Default is 0. | ||||||
|     */ |     */ | ||||||
|    static void SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                units::angle::degrees<double>           latitude, |                         units::angle::degrees<double>           latitude, | ||||||
|                                units::angle::degrees<double> longitude, |                         units::angle::degrees<double>           longitude, | ||||||
|                                double                        xOffset = 0.0, |                         double                                  xOffset = 0.0, | ||||||
|                                double                        yOffset = 0.0); |                         double                                  yOffset = 0.0); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the location of a geo icon. |     * Sets the location of a geo icon. | ||||||
|  | @ -129,11 +136,11 @@ public: | ||||||
|     * @param [in] xOffset The x-offset of the geo icon in pixels. Default is 0. |     * @param [in] xOffset The x-offset of the geo icon in pixels. Default is 0. | ||||||
|     * @param [in] yOffset The y-offset of the geo icon in pixels. Default is 0. |     * @param [in] yOffset The y-offset of the geo icon in pixels. Default is 0. | ||||||
|     */ |     */ | ||||||
|    static void SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconLocation(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                double                                  latitude, |                         double                                  latitude, | ||||||
|                                double longitude, |                         double                                  longitude, | ||||||
|                                double xOffset = 0.0, |                         double                                  xOffset = 0.0, | ||||||
|                                double yOffset = 0.0); |                         double                                  yOffset = 0.0); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the angle of a geo icon. |     * Sets the angle of a geo icon. | ||||||
|  | @ -141,8 +148,8 @@ public: | ||||||
|     * @param [in] di Geo icon draw item |     * @param [in] di Geo icon draw item | ||||||
|     * @param [in] angle Angle in degrees |     * @param [in] angle Angle in degrees | ||||||
|     */ |     */ | ||||||
|    static void SetIconAngle(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconAngle(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                             units::angle::degrees<double>           angle); |                      units::angle::degrees<double>           angle); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the modulate color of a geo icon. |     * Sets the modulate color of a geo icon. | ||||||
|  | @ -150,8 +157,8 @@ public: | ||||||
|     * @param [in] di Geo icon draw item |     * @param [in] di Geo icon draw item | ||||||
|     * @param [in] modulate Modulate color |     * @param [in] modulate Modulate color | ||||||
|     */ |     */ | ||||||
|    static void SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                boost::gil::rgba8_pixel_t modulate); |                         boost::gil::rgba8_pixel_t               modulate); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the modulate color of a geo icon. |     * Sets the modulate color of a geo icon. | ||||||
|  | @ -159,8 +166,8 @@ public: | ||||||
|     * @param [in] di Geo icon draw item |     * @param [in] di Geo icon draw item | ||||||
|     * @param [in] modulate Modulate color |     * @param [in] modulate Modulate color | ||||||
|     */ |     */ | ||||||
|    static void SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconModulate(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                boost::gil::rgba32f_pixel_t modulate); |                         boost::gil::rgba32f_pixel_t             modulate); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Sets the hover text of a geo icon. |     * Sets the hover text of a geo icon. | ||||||
|  | @ -168,8 +175,8 @@ public: | ||||||
|     * @param [in] di Geo icon draw item |     * @param [in] di Geo icon draw item | ||||||
|     * @param [in] text Hover text |     * @param [in] text Hover text | ||||||
|     */ |     */ | ||||||
|    static void SetIconHoverText(const std::shared_ptr<GeoIconDrawItem>& di, |    void SetIconHoverText(const std::shared_ptr<GeoIconDrawItem>& di, | ||||||
|                                 const std::string&                      text); |                          const std::string&                      text); | ||||||
| 
 | 
 | ||||||
|    /**
 |    /**
 | ||||||
|     * Finalizes the draw item after adding new icons. |     * Finalizes the draw item after adding new icons. | ||||||
|  |  | ||||||
|  | @ -136,7 +136,8 @@ void GeoLines::set_thresholded(bool thresholded) | ||||||
| 
 | 
 | ||||||
| void GeoLines::Initialize() | void GeoLines::Initialize() | ||||||
| { | { | ||||||
|    gl::OpenGLFunctions& gl = p->context_->gl(); |    gl::OpenGLFunctions& gl   = p->context_->gl(); | ||||||
|  |    auto&                gl30 = p->context_->gl30(); | ||||||
| 
 | 
 | ||||||
|    p->shaderProgram_ = p->context_->GetShaderProgram( |    p->shaderProgram_ = p->context_->GetShaderProgram( | ||||||
|       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, |       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, | ||||||
|  | @ -215,6 +216,9 @@ void GeoLines::Initialize() | ||||||
|                              reinterpret_cast<void*>(1 * sizeof(GLint))); |                              reinterpret_cast<void*>(1 * sizeof(GLint))); | ||||||
|    gl.glEnableVertexAttribArray(6); |    gl.glEnableVertexAttribArray(6); | ||||||
| 
 | 
 | ||||||
|  |    // aDisplayed
 | ||||||
|  |    gl30.glVertexAttribI1i(7, 1); | ||||||
|  | 
 | ||||||
|    p->dirty_ = true; |    p->dirty_ = true; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -179,7 +179,7 @@ void Icons::Initialize() | ||||||
|                             reinterpret_cast<void*>(8 * sizeof(float))); |                             reinterpret_cast<void*>(8 * sizeof(float))); | ||||||
|    gl.glEnableVertexAttribArray(4); |    gl.glEnableVertexAttribArray(4); | ||||||
| 
 | 
 | ||||||
|    // aAngle
 |    // aDisplayed
 | ||||||
|    gl.glVertexAttribPointer(5, |    gl.glVertexAttribPointer(5, | ||||||
|                             1, |                             1, | ||||||
|                             GL_FLOAT, |                             GL_FLOAT, | ||||||
|  | @ -316,57 +316,80 @@ std::shared_ptr<IconDrawItem> Icons::AddIcon() | ||||||
| void Icons::SetIconVisible(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconVisible(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                            bool                                 visible) |                            bool                                 visible) | ||||||
| { | { | ||||||
|    di->visible_ = visible; |    if (di->visible_ != visible) | ||||||
|    p->dirtyIcons_.insert(di); |    { | ||||||
|  |       di->visible_ = visible; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconTexture(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconTexture(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                            const std::string&                   iconSheet, |                            const std::string&                   iconSheet, | ||||||
|                            std::size_t                          iconIndex) |                            std::size_t                          iconIndex) | ||||||
| { | { | ||||||
|    di->iconSheet_ = iconSheet; |    if (di->iconSheet_ != iconSheet || di->iconIndex_ != iconIndex) | ||||||
|    di->iconIndex_ = iconIndex; |    { | ||||||
|    p->dirtyIcons_.insert(di); |       di->iconSheet_ = iconSheet; | ||||||
|  |       di->iconIndex_ = iconIndex; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconLocation(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconLocation(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                             double                               x, |                             double                               x, | ||||||
|                             double                               y) |                             double                               y) | ||||||
| { | { | ||||||
|    di->x_ = x; |    if (di->x_ != x || di->y_ != y) | ||||||
|    di->y_ = y; |    { | ||||||
|    p->dirtyIcons_.insert(di); |       di->x_ = x; | ||||||
|  |       di->y_ = y; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconAngle(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconAngle(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                          units::angle::degrees<double>        angle) |                          units::angle::degrees<double>        angle) | ||||||
| { | { | ||||||
|    di->angle_ = angle; |    if (di->angle_ != angle) | ||||||
|    p->dirtyIcons_.insert(di); |    { | ||||||
|  |       di->angle_ = angle; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconModulate(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconModulate(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                             boost::gil::rgba8_pixel_t            modulate) |                             boost::gil::rgba8_pixel_t            modulate) | ||||||
| { | { | ||||||
|    di->modulate_ = {modulate[0] / 255.0f, |    boost::gil::rgba32f_pixel_t newModulate = {modulate[0] / 255.0f, | ||||||
|                     modulate[1] / 255.0f, |                                               modulate[1] / 255.0f, | ||||||
|                     modulate[2] / 255.0f, |                                               modulate[2] / 255.0f, | ||||||
|                     modulate[3] / 255.0f}; |                                               modulate[3] / 255.0f}; | ||||||
|    p->dirtyIcons_.insert(di); | 
 | ||||||
|  |    if (di->modulate_ != newModulate) | ||||||
|  |    { | ||||||
|  |       di->modulate_ = newModulate; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconModulate(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconModulate(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                             boost::gil::rgba32f_pixel_t          modulate) |                             boost::gil::rgba32f_pixel_t          modulate) | ||||||
| { | { | ||||||
|    di->modulate_ = modulate; |    if (di->modulate_ != modulate) | ||||||
|    p->dirtyIcons_.insert(di); |    { | ||||||
|  |       di->modulate_ = modulate; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::SetIconHoverText(const std::shared_ptr<IconDrawItem>& di, | void Icons::SetIconHoverText(const std::shared_ptr<IconDrawItem>& di, | ||||||
|                              const std::string&                   text) |                              const std::string&                   text) | ||||||
| { | { | ||||||
|    di->hoverText_ = text; |    if (di->hoverText_ != text) | ||||||
|    p->dirtyIcons_.insert(di); |    { | ||||||
|  |       di->hoverText_ = text; | ||||||
|  |       p->dirtyIcons_.insert(di); | ||||||
|  |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| void Icons::FinishIcons() | void Icons::FinishIcons() | ||||||
|  |  | ||||||
|  | @ -161,7 +161,8 @@ void PlacefileIcons::set_thresholded(bool thresholded) | ||||||
| 
 | 
 | ||||||
| void PlacefileIcons::Initialize() | void PlacefileIcons::Initialize() | ||||||
| { | { | ||||||
|    gl::OpenGLFunctions& gl = p->context_->gl(); |    gl::OpenGLFunctions& gl   = p->context_->gl(); | ||||||
|  |    auto&                gl30 = p->context_->gl30(); | ||||||
| 
 | 
 | ||||||
|    p->shaderProgram_ = p->context_->GetShaderProgram( |    p->shaderProgram_ = p->context_->GetShaderProgram( | ||||||
|       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, |       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, | ||||||
|  | @ -251,6 +252,9 @@ void PlacefileIcons::Initialize() | ||||||
|                              reinterpret_cast<void*>(1 * sizeof(GLint))); |                              reinterpret_cast<void*>(1 * sizeof(GLint))); | ||||||
|    gl.glEnableVertexAttribArray(6); |    gl.glEnableVertexAttribArray(6); | ||||||
| 
 | 
 | ||||||
|  |    // aDisplayed
 | ||||||
|  |    gl30.glVertexAttribI1i(7, 1); | ||||||
|  | 
 | ||||||
|    p->dirty_ = true; |    p->dirty_ = true; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -139,7 +139,8 @@ void PlacefileImages::set_thresholded(bool thresholded) | ||||||
| 
 | 
 | ||||||
| void PlacefileImages::Initialize() | void PlacefileImages::Initialize() | ||||||
| { | { | ||||||
|    gl::OpenGLFunctions& gl = p->context_->gl(); |    gl::OpenGLFunctions& gl   = p->context_->gl(); | ||||||
|  |    auto&                gl30 = p->context_->gl30(); | ||||||
| 
 | 
 | ||||||
|    p->shaderProgram_ = p->context_->GetShaderProgram( |    p->shaderProgram_ = p->context_->GetShaderProgram( | ||||||
|       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, |       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, | ||||||
|  | @ -220,6 +221,9 @@ void PlacefileImages::Initialize() | ||||||
|                              reinterpret_cast<void*>(1 * sizeof(GLint))); |                              reinterpret_cast<void*>(1 * sizeof(GLint))); | ||||||
|    gl.glEnableVertexAttribArray(6); |    gl.glEnableVertexAttribArray(6); | ||||||
| 
 | 
 | ||||||
|  |    // aDisplayed
 | ||||||
|  |    gl30.glVertexAttribI1i(7, 1); | ||||||
|  | 
 | ||||||
|    p->dirty_ = true; |    p->dirty_ = true; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -131,7 +131,8 @@ void PlacefileLines::set_thresholded(bool thresholded) | ||||||
| 
 | 
 | ||||||
| void PlacefileLines::Initialize() | void PlacefileLines::Initialize() | ||||||
| { | { | ||||||
|    gl::OpenGLFunctions& gl = p->context_->gl(); |    gl::OpenGLFunctions& gl   = p->context_->gl(); | ||||||
|  |    auto&                gl30 = p->context_->gl30(); | ||||||
| 
 | 
 | ||||||
|    p->shaderProgram_ = p->context_->GetShaderProgram( |    p->shaderProgram_ = p->context_->GetShaderProgram( | ||||||
|       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, |       {{GL_VERTEX_SHADER, ":/gl/geo_texture2d.vert"}, | ||||||
|  | @ -209,6 +210,9 @@ void PlacefileLines::Initialize() | ||||||
|                              reinterpret_cast<void*>(1 * sizeof(GLint))); |                              reinterpret_cast<void*>(1 * sizeof(GLint))); | ||||||
|    gl.glEnableVertexAttribArray(6); |    gl.glEnableVertexAttribArray(6); | ||||||
| 
 | 
 | ||||||
|  |    // aDisplayed
 | ||||||
|  |    gl30.glVertexAttribI1i(7, 1); | ||||||
|  | 
 | ||||||
|    p->dirty_ = true; |    p->dirty_ = true; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -31,7 +31,8 @@ public: | ||||||
|    static std::size_t |    static std::size_t | ||||||
|    GetShaderKey(std::initializer_list<std::pair<GLenum, std::string>> shaders); |    GetShaderKey(std::initializer_list<std::pair<GLenum, std::string>> shaders); | ||||||
| 
 | 
 | ||||||
|    gl::OpenGLFunctions gl_; |    gl::OpenGLFunctions  gl_; | ||||||
|  |    QOpenGLFunctions_3_0 gl30_; | ||||||
| 
 | 
 | ||||||
|    bool glInitialized_ {false}; |    bool glInitialized_ {false}; | ||||||
| 
 | 
 | ||||||
|  | @ -56,6 +57,11 @@ gl::OpenGLFunctions& GlContext::gl() | ||||||
|    return p->gl_; |    return p->gl_; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | QOpenGLFunctions_3_0& GlContext::gl30() | ||||||
|  | { | ||||||
|  |    return p->gl30_; | ||||||
|  | } | ||||||
|  | 
 | ||||||
| std::uint64_t GlContext::texture_buffer_count() const | std::uint64_t GlContext::texture_buffer_count() const | ||||||
| { | { | ||||||
|    return p->textureBufferCount_; |    return p->textureBufferCount_; | ||||||
|  | @ -68,6 +74,9 @@ void GlContext::Impl::InitializeGL() | ||||||
|       return; |       return; | ||||||
|    } |    } | ||||||
| 
 | 
 | ||||||
|  |    gl_.initializeOpenGLFunctions(); | ||||||
|  |    gl30_.initializeOpenGLFunctions(); | ||||||
|  | 
 | ||||||
|    gl_.glGenTextures(1, &textureAtlas_); |    gl_.glGenTextures(1, &textureAtlas_); | ||||||
| 
 | 
 | ||||||
|    glInitialized_ = true; |    glInitialized_ = true; | ||||||
|  | @ -122,6 +131,11 @@ GLuint GlContext::GetTextureAtlas() | ||||||
|    return p->textureAtlas_; |    return p->textureAtlas_; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | void GlContext::Initialize() | ||||||
|  | { | ||||||
|  |    p->InitializeGL(); | ||||||
|  | } | ||||||
|  | 
 | ||||||
| std::size_t GlContext::Impl::GetShaderKey( | std::size_t GlContext::Impl::GetShaderKey( | ||||||
|    std::initializer_list<std::pair<GLenum, std::string>> shaders) |    std::initializer_list<std::pair<GLenum, std::string>> shaders) | ||||||
| { | { | ||||||
|  |  | ||||||
|  | @ -3,6 +3,8 @@ | ||||||
| #include <scwx/qt/gl/gl.hpp> | #include <scwx/qt/gl/gl.hpp> | ||||||
| #include <scwx/qt/gl/shader_program.hpp> | #include <scwx/qt/gl/shader_program.hpp> | ||||||
| 
 | 
 | ||||||
|  | #include <QOpenGLFunctions_3_0> | ||||||
|  | 
 | ||||||
| namespace scwx | namespace scwx | ||||||
| { | { | ||||||
| namespace qt | namespace qt | ||||||
|  | @ -22,7 +24,8 @@ public: | ||||||
|    GlContext(GlContext&&) noexcept; |    GlContext(GlContext&&) noexcept; | ||||||
|    GlContext& operator=(GlContext&&) noexcept; |    GlContext& operator=(GlContext&&) noexcept; | ||||||
| 
 | 
 | ||||||
|    gl::OpenGLFunctions& gl(); |    gl::OpenGLFunctions&  gl(); | ||||||
|  |    QOpenGLFunctions_3_0& gl30(); | ||||||
| 
 | 
 | ||||||
|    std::uint64_t texture_buffer_count() const; |    std::uint64_t texture_buffer_count() const; | ||||||
| 
 | 
 | ||||||
|  | @ -34,6 +37,8 @@ public: | ||||||
| 
 | 
 | ||||||
|    GLuint GetTextureAtlas(); |    GLuint GetTextureAtlas(); | ||||||
| 
 | 
 | ||||||
|  |    void Initialize(); | ||||||
|  | 
 | ||||||
| private: | private: | ||||||
|    class Impl; |    class Impl; | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -824,6 +824,11 @@ void MainWindowImpl::ConnectMapSignals() | ||||||
|             coordinateLabel_->setText( |             coordinateLabel_->setText( | ||||||
|                QString("%1, %2").arg(latitude).arg(longitude)); |                QString("%1, %2").arg(latitude).arg(longitude)); | ||||||
|             coordinateLabel_->setVisible(true); |             coordinateLabel_->setVisible(true); | ||||||
|  | 
 | ||||||
|  |             for (auto& map : maps_) | ||||||
|  |             { | ||||||
|  |                map->UpdateMouseCoordinate(coordinate); | ||||||
|  |             } | ||||||
|          }, |          }, | ||||||
|          Qt::QueuedConnection); |          Qt::QueuedConnection); | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -32,7 +32,8 @@ public: | ||||||
|    MapProvider mapProvider_ {MapProvider::Unknown}; |    MapProvider mapProvider_ {MapProvider::Unknown}; | ||||||
|    std::string mapCopyrights_ {}; |    std::string mapCopyrights_ {}; | ||||||
| 
 | 
 | ||||||
|    QMargins colorTableMargins_ {}; |    QMargins           colorTableMargins_ {}; | ||||||
|  |    common::Coordinate mouseCoordinate_ {}; | ||||||
| 
 | 
 | ||||||
|    std::shared_ptr<view::OverlayProductView> overlayProductView_ {nullptr}; |    std::shared_ptr<view::OverlayProductView> overlayProductView_ {nullptr}; | ||||||
|    std::shared_ptr<view::RadarProductView>   radarProductView_; |    std::shared_ptr<view::RadarProductView>   radarProductView_; | ||||||
|  | @ -78,6 +79,11 @@ float MapContext::pixel_ratio() const | ||||||
|    return p->pixelRatio_; |    return p->pixelRatio_; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | common::Coordinate MapContext::mouse_coordinate() const | ||||||
|  | { | ||||||
|  |    return p->mouseCoordinate_; | ||||||
|  | } | ||||||
|  | 
 | ||||||
| std::shared_ptr<view::OverlayProductView> | std::shared_ptr<view::OverlayProductView> | ||||||
| MapContext::overlay_product_view() const | MapContext::overlay_product_view() const | ||||||
| { | { | ||||||
|  | @ -129,6 +135,11 @@ void MapContext::set_color_table_margins(const QMargins& margins) | ||||||
|    p->colorTableMargins_ = margins; |    p->colorTableMargins_ = margins; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | void MapContext::set_mouse_coordinate(const common::Coordinate& coordinate) | ||||||
|  | { | ||||||
|  |    p->mouseCoordinate_ = coordinate; | ||||||
|  | } | ||||||
|  | 
 | ||||||
| void MapContext::set_overlay_product_view( | void MapContext::set_overlay_product_view( | ||||||
|    const std::shared_ptr<view::OverlayProductView>& overlayProductView) |    const std::shared_ptr<view::OverlayProductView>& overlayProductView) | ||||||
| { | { | ||||||
|  |  | ||||||
|  | @ -2,6 +2,7 @@ | ||||||
| 
 | 
 | ||||||
| #include <scwx/qt/gl/gl_context.hpp> | #include <scwx/qt/gl/gl_context.hpp> | ||||||
| #include <scwx/qt/map/map_provider.hpp> | #include <scwx/qt/map/map_provider.hpp> | ||||||
|  | #include <scwx/common/geographic.hpp> | ||||||
| #include <scwx/common/products.hpp> | #include <scwx/common/products.hpp> | ||||||
| 
 | 
 | ||||||
| #include <qmaplibre.hpp> | #include <qmaplibre.hpp> | ||||||
|  | @ -43,6 +44,7 @@ public: | ||||||
|    MapSettings&                              settings(); |    MapSettings&                              settings(); | ||||||
|    QMargins                                  color_table_margins() const; |    QMargins                                  color_table_margins() const; | ||||||
|    float                                     pixel_ratio() const; |    float                                     pixel_ratio() const; | ||||||
|  |    common::Coordinate                        mouse_coordinate() const; | ||||||
|    std::shared_ptr<view::OverlayProductView> overlay_product_view() const; |    std::shared_ptr<view::OverlayProductView> overlay_product_view() const; | ||||||
|    std::shared_ptr<view::RadarProductView>   radar_product_view() const; |    std::shared_ptr<view::RadarProductView>   radar_product_view() const; | ||||||
|    common::RadarProductGroup                 radar_product_group() const; |    common::RadarProductGroup                 radar_product_group() const; | ||||||
|  | @ -54,6 +56,7 @@ public: | ||||||
|    void set_map_copyrights(const std::string& copyrights); |    void set_map_copyrights(const std::string& copyrights); | ||||||
|    void set_map_provider(MapProvider provider); |    void set_map_provider(MapProvider provider); | ||||||
|    void set_color_table_margins(const QMargins& margins); |    void set_color_table_margins(const QMargins& margins); | ||||||
|  |    void set_mouse_coordinate(const common::Coordinate& coordinate); | ||||||
|    void set_overlay_product_view( |    void set_overlay_product_view( | ||||||
|       const std::shared_ptr<view::OverlayProductView>& overlayProductView); |       const std::shared_ptr<view::OverlayProductView>& overlayProductView); | ||||||
|    void set_pixel_ratio(float pixelRatio); |    void set_pixel_ratio(float pixelRatio); | ||||||
|  |  | ||||||
|  | @ -224,6 +224,9 @@ public: | ||||||
|    const MapStyle* currentStyle_; |    const MapStyle* currentStyle_; | ||||||
|    std::string     initialStyleName_ {}; |    std::string     initialStyleName_ {}; | ||||||
| 
 | 
 | ||||||
|  |    Qt::KeyboardModifiers lastKeyboardModifiers_ { | ||||||
|  |       Qt::KeyboardModifier::NoModifier}; | ||||||
|  | 
 | ||||||
|    std::shared_ptr<types::EventHandler> pickedEventHandler_ {nullptr}; |    std::shared_ptr<types::EventHandler> pickedEventHandler_ {nullptr}; | ||||||
| 
 | 
 | ||||||
|    uint64_t frameDraws_; |    uint64_t frameDraws_; | ||||||
|  | @ -940,6 +943,24 @@ void MapWidget::SetMapStyle(const std::string& styleName) | ||||||
|    } |    } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | void MapWidget::UpdateMouseCoordinate(const common::Coordinate& coordinate) | ||||||
|  | { | ||||||
|  |    if (p->context_->mouse_coordinate() != coordinate) | ||||||
|  |    { | ||||||
|  |       p->context_->set_mouse_coordinate(coordinate); | ||||||
|  | 
 | ||||||
|  |       auto keyboardModifiers = QGuiApplication::keyboardModifiers(); | ||||||
|  | 
 | ||||||
|  |       if (keyboardModifiers != Qt::KeyboardModifier::NoModifier || | ||||||
|  |           keyboardModifiers != p->lastKeyboardModifiers_) | ||||||
|  |       { | ||||||
|  |          update(); | ||||||
|  |       } | ||||||
|  | 
 | ||||||
|  |       p->lastKeyboardModifiers_ = keyboardModifiers; | ||||||
|  |    } | ||||||
|  | } | ||||||
|  | 
 | ||||||
| qreal MapWidget::pixelRatio() | qreal MapWidget::pixelRatio() | ||||||
| { | { | ||||||
|    return devicePixelRatioF(); |    return devicePixelRatioF(); | ||||||
|  | @ -1311,7 +1332,7 @@ void MapWidget::initializeGL() | ||||||
|    logger_->debug("initializeGL()"); |    logger_->debug("initializeGL()"); | ||||||
| 
 | 
 | ||||||
|    makeCurrent(); |    makeCurrent(); | ||||||
|    p->context_->gl().initializeOpenGLFunctions(); |    p->context_->Initialize(); | ||||||
| 
 | 
 | ||||||
|    // Lock ImGui font atlas prior to new ImGui frame
 |    // Lock ImGui font atlas prior to new ImGui frame
 | ||||||
|    std::shared_lock imguiFontAtlasLock { |    std::shared_lock imguiFontAtlasLock { | ||||||
|  |  | ||||||
|  | @ -117,6 +117,13 @@ public: | ||||||
|    void SetInitialMapStyle(const std::string& styleName); |    void SetInitialMapStyle(const std::string& styleName); | ||||||
|    void SetMapStyle(const std::string& styleName); |    void SetMapStyle(const std::string& styleName); | ||||||
| 
 | 
 | ||||||
|  |    /**
 | ||||||
|  |     * Updates the coordinates associated with mouse movement from another map. | ||||||
|  |     * | ||||||
|  |     * @param [in] coordinate Coordinate of the mouse | ||||||
|  |     */ | ||||||
|  |    void UpdateMouseCoordinate(const common::Coordinate& coordinate); | ||||||
|  | 
 | ||||||
| private: | private: | ||||||
|    void  changeStyle(); |    void  changeStyle(); | ||||||
|    qreal pixelRatio(); |    qreal pixelRatio(); | ||||||
|  |  | ||||||
|  | @ -19,6 +19,7 @@ | ||||||
| 
 | 
 | ||||||
| #include <imgui.h> | #include <imgui.h> | ||||||
| #include <QGeoPositionInfo> | #include <QGeoPositionInfo> | ||||||
|  | #include <QGuiApplication> | ||||||
| #include <QMouseEvent> | #include <QMouseEvent> | ||||||
| 
 | 
 | ||||||
| #if !defined(_MSC_VER) | #if !defined(_MSC_VER) | ||||||
|  | @ -69,6 +70,9 @@ public: | ||||||
|       showMapAttributionCallbackUuid_ = |       showMapAttributionCallbackUuid_ = | ||||||
|          generalSettings.show_map_attribution().RegisterValueChangedCallback( |          generalSettings.show_map_attribution().RegisterValueChangedCallback( | ||||||
|             [this](const bool&) { Q_EMIT self_->NeedsRendering(); }); |             [this](const bool&) { Q_EMIT self_->NeedsRendering(); }); | ||||||
|  |       showMapCenterCallbackUuid_ = | ||||||
|  |          generalSettings.show_map_center().RegisterValueChangedCallback( | ||||||
|  |             [this](const bool&) { Q_EMIT self_->NeedsRendering(); }); | ||||||
|       showMapLogoCallbackUuid_ = |       showMapLogoCallbackUuid_ = | ||||||
|          generalSettings.show_map_logo().RegisterValueChangedCallback( |          generalSettings.show_map_logo().RegisterValueChangedCallback( | ||||||
|             [this](const bool&) { Q_EMIT self_->NeedsRendering(); }); |             [this](const bool&) { Q_EMIT self_->NeedsRendering(); }); | ||||||
|  | @ -84,6 +88,8 @@ public: | ||||||
|          defaultTimeZoneCallbackUuid_); |          defaultTimeZoneCallbackUuid_); | ||||||
|       generalSettings.show_map_attribution().UnregisterValueChangedCallback( |       generalSettings.show_map_attribution().UnregisterValueChangedCallback( | ||||||
|          showMapAttributionCallbackUuid_); |          showMapAttributionCallbackUuid_); | ||||||
|  |       generalSettings.show_map_center().UnregisterValueChangedCallback( | ||||||
|  |          showMapCenterCallbackUuid_); | ||||||
|       generalSettings.show_map_logo().UnregisterValueChangedCallback( |       generalSettings.show_map_logo().UnregisterValueChangedCallback( | ||||||
|          showMapLogoCallbackUuid_); |          showMapLogoCallbackUuid_); | ||||||
|    } |    } | ||||||
|  | @ -93,6 +99,7 @@ public: | ||||||
|    boost::uuids::uuid clockFormatCallbackUuid_; |    boost::uuids::uuid clockFormatCallbackUuid_; | ||||||
|    boost::uuids::uuid defaultTimeZoneCallbackUuid_; |    boost::uuids::uuid defaultTimeZoneCallbackUuid_; | ||||||
|    boost::uuids::uuid showMapAttributionCallbackUuid_; |    boost::uuids::uuid showMapAttributionCallbackUuid_; | ||||||
|  |    boost::uuids::uuid showMapCenterCallbackUuid_; | ||||||
|    boost::uuids::uuid showMapLogoCallbackUuid_; |    boost::uuids::uuid showMapLogoCallbackUuid_; | ||||||
| 
 | 
 | ||||||
|    std::shared_ptr<manager::PositionManager> positionManager_ { |    std::shared_ptr<manager::PositionManager> positionManager_ { | ||||||
|  | @ -108,10 +115,16 @@ public: | ||||||
|       types::GetTextureName(types::ImageTexture::Crosshairs24)}; |       types::GetTextureName(types::ImageTexture::Crosshairs24)}; | ||||||
|    std::shared_ptr<gl::draw::GeoIconDrawItem> locationIcon_ {}; |    std::shared_ptr<gl::draw::GeoIconDrawItem> locationIcon_ {}; | ||||||
| 
 | 
 | ||||||
|  |    std::shared_ptr<gl::draw::GeoIconDrawItem> cursorIcon_ {}; | ||||||
|  | 
 | ||||||
|    const std::string& cardinalPointIconName_ { |    const std::string& cardinalPointIconName_ { | ||||||
|       types::GetTextureName(types::ImageTexture::CardinalPoint24)}; |       types::GetTextureName(types::ImageTexture::CardinalPoint24)}; | ||||||
|    const std::string& compassIconName_ { |    const std::string& compassIconName_ { | ||||||
|       types::GetTextureName(types::ImageTexture::Compass24)}; |       types::GetTextureName(types::ImageTexture::Compass24)}; | ||||||
|  |    const std::string& cursorIconName_ { | ||||||
|  |       types::GetTextureName(types::ImageTexture::Dot3)}; | ||||||
|  |    const std::string& mapCenterIconName_ { | ||||||
|  |       types::GetTextureName(types::ImageTexture::Cursor17)}; | ||||||
| 
 | 
 | ||||||
|    const std::string& mapboxLogoImageName_ { |    const std::string& mapboxLogoImageName_ { | ||||||
|       types::GetTextureName(types::ImageTexture::MapboxLogo)}; |       types::GetTextureName(types::ImageTexture::MapboxLogo)}; | ||||||
|  | @ -119,6 +132,7 @@ public: | ||||||
|       types::GetTextureName(types::ImageTexture::MapTilerLogo)}; |       types::GetTextureName(types::ImageTexture::MapTilerLogo)}; | ||||||
| 
 | 
 | ||||||
|    std::shared_ptr<gl::draw::IconDrawItem> compassIcon_ {}; |    std::shared_ptr<gl::draw::IconDrawItem> compassIcon_ {}; | ||||||
|  |    std::shared_ptr<gl::draw::IconDrawItem> mapCenterIcon_ {}; | ||||||
|    double                                  lastBearing_ {0.0}; |    double                                  lastBearing_ {0.0}; | ||||||
| 
 | 
 | ||||||
|    std::shared_ptr<gl::draw::IconDrawItem> mapLogoIcon_ {}; |    std::shared_ptr<gl::draw::IconDrawItem> mapLogoIcon_ {}; | ||||||
|  | @ -168,23 +182,29 @@ void OverlayLayer::Initialize() | ||||||
| 
 | 
 | ||||||
|    // Geo Icons
 |    // Geo Icons
 | ||||||
|    p->geoIcons_->StartIconSheets(); |    p->geoIcons_->StartIconSheets(); | ||||||
|  |    p->geoIcons_->AddIconSheet(p->cursorIconName_); | ||||||
|    p->geoIcons_->AddIconSheet(p->locationIconName_); |    p->geoIcons_->AddIconSheet(p->locationIconName_); | ||||||
|    p->geoIcons_->FinishIconSheets(); |    p->geoIcons_->FinishIconSheets(); | ||||||
| 
 | 
 | ||||||
|    p->geoIcons_->StartIcons(); |    p->geoIcons_->StartIcons(); | ||||||
|  | 
 | ||||||
|  |    p->cursorIcon_ = p->geoIcons_->AddIcon(); | ||||||
|  |    p->geoIcons_->SetIconTexture(p->cursorIcon_, p->cursorIconName_, 0); | ||||||
|  | 
 | ||||||
|    p->locationIcon_ = p->geoIcons_->AddIcon(); |    p->locationIcon_ = p->geoIcons_->AddIcon(); | ||||||
|    gl::draw::GeoIcons::SetIconTexture( |    p->geoIcons_->SetIconTexture(p->locationIcon_, p->locationIconName_, 0); | ||||||
|       p->locationIcon_, p->locationIconName_, 0); |    p->geoIcons_->SetIconAngle(p->locationIcon_, | ||||||
|    gl::draw::GeoIcons::SetIconAngle(p->locationIcon_, |                               units::angle::degrees<double> {45.0}); | ||||||
|                                     units::angle::degrees<double> {45.0}); |    p->geoIcons_->SetIconLocation( | ||||||
|    gl::draw::GeoIcons::SetIconLocation( |  | ||||||
|       p->locationIcon_, coordinate.latitude(), coordinate.longitude()); |       p->locationIcon_, coordinate.latitude(), coordinate.longitude()); | ||||||
|  | 
 | ||||||
|    p->geoIcons_->FinishIcons(); |    p->geoIcons_->FinishIcons(); | ||||||
| 
 | 
 | ||||||
|    // Icons
 |    // Icons
 | ||||||
|    p->icons_->StartIconSheets(); |    p->icons_->StartIconSheets(); | ||||||
|    p->icons_->AddIconSheet(p->cardinalPointIconName_); |    p->icons_->AddIconSheet(p->cardinalPointIconName_); | ||||||
|    p->icons_->AddIconSheet(p->compassIconName_); |    p->icons_->AddIconSheet(p->compassIconName_); | ||||||
|  |    p->icons_->AddIconSheet(p->mapCenterIconName_); | ||||||
|    p->icons_->AddIconSheet(p->mapboxLogoImageName_)->SetAnchor(0.0f, 1.0f); |    p->icons_->AddIconSheet(p->mapboxLogoImageName_)->SetAnchor(0.0f, 1.0f); | ||||||
|    p->icons_->AddIconSheet(p->mapTilerLogoImageName_)->SetAnchor(0.0f, 1.0f); |    p->icons_->AddIconSheet(p->mapTilerLogoImageName_)->SetAnchor(0.0f, 1.0f); | ||||||
|    p->icons_->FinishIconSheets(); |    p->icons_->FinishIconSheets(); | ||||||
|  | @ -234,6 +254,9 @@ void OverlayLayer::Initialize() | ||||||
|          } |          } | ||||||
|       }); |       }); | ||||||
| 
 | 
 | ||||||
|  |    p->mapCenterIcon_ = p->icons_->AddIcon(); | ||||||
|  |    p->icons_->SetIconTexture(p->mapCenterIcon_, p->mapCenterIconName_, 0); | ||||||
|  | 
 | ||||||
|    p->mapLogoIcon_ = p->icons_->AddIcon(); |    p->mapLogoIcon_ = p->icons_->AddIcon(); | ||||||
|    if (context()->map_provider() == MapProvider::Mapbox) |    if (context()->map_provider() == MapProvider::Mapbox) | ||||||
|    { |    { | ||||||
|  | @ -259,10 +282,9 @@ void OverlayLayer::Initialize() | ||||||
|               if (position.isValid() && |               if (position.isValid() && | ||||||
|                   p->currentPosition_.coordinate() != coordinate) |                   p->currentPosition_.coordinate() != coordinate) | ||||||
|               { |               { | ||||||
|                  gl::draw::GeoIcons::SetIconLocation(p->locationIcon_, |                  p->geoIcons_->SetIconLocation(p->locationIcon_, | ||||||
|                                                      coordinate.latitude(), |                                                coordinate.latitude(), | ||||||
|                                                      coordinate.longitude()); |                                                coordinate.longitude()); | ||||||
|                  p->geoIcons_->FinishIcons(); |  | ||||||
|                  Q_EMIT NeedsRendering(); |                  Q_EMIT NeedsRendering(); | ||||||
|               } |               } | ||||||
|               p->currentPosition_ = position; |               p->currentPosition_ = position; | ||||||
|  | @ -315,9 +337,21 @@ void OverlayLayer::Render(const QMapLibre::CustomLayerRenderParameters& params) | ||||||
|       p->activeBoxInner_->SetBorder(1.0f * pixelRatio, {255, 255, 255, 255}); |       p->activeBoxInner_->SetBorder(1.0f * pixelRatio, {255, 255, 255, 255}); | ||||||
|    } |    } | ||||||
| 
 | 
 | ||||||
|  |    // Cursor Icon
 | ||||||
|  |    bool cursorIconVisible = QGuiApplication::keyboardModifiers() & | ||||||
|  |                             Qt::KeyboardModifier::ControlModifier; | ||||||
|  |    p->geoIcons_->SetIconVisible(p->cursorIcon_, cursorIconVisible); | ||||||
|  |    if (cursorIconVisible) | ||||||
|  |    { | ||||||
|  |       common::Coordinate mouseCoordinate = context()->mouse_coordinate(); | ||||||
|  |       p->geoIcons_->SetIconLocation( | ||||||
|  |          p->cursorIcon_, mouseCoordinate.latitude_, mouseCoordinate.longitude_); | ||||||
|  |    } | ||||||
|  | 
 | ||||||
|    // Location Icon
 |    // Location Icon
 | ||||||
|    p->geoIcons_->SetVisible(p->currentPosition_.isValid() && |    p->geoIcons_->SetIconVisible(p->locationIcon_, | ||||||
|                             p->positionManager_->IsLocationTracked()); |                                 p->currentPosition_.isValid() && | ||||||
|  |                                    p->positionManager_->IsLocationTracked()); | ||||||
| 
 | 
 | ||||||
|    // Compass Icon
 |    // Compass Icon
 | ||||||
|    if (params.width != p->lastWidth_ || params.height != p->lastHeight_ || |    if (params.width != p->lastWidth_ || params.height != p->lastHeight_ || | ||||||
|  | @ -411,6 +445,16 @@ void OverlayLayer::Render(const QMapLibre::CustomLayerRenderParameters& params) | ||||||
| 
 | 
 | ||||||
|    auto& generalSettings = settings::GeneralSettings::Instance(); |    auto& generalSettings = settings::GeneralSettings::Instance(); | ||||||
| 
 | 
 | ||||||
|  |    // Map Center Icon
 | ||||||
|  |    if (params.width != p->lastWidth_ || params.height != p->lastHeight_) | ||||||
|  |    { | ||||||
|  |       // Draw the icon in the center of the widget
 | ||||||
|  |       p->icons_->SetIconLocation( | ||||||
|  |          p->mapCenterIcon_, params.width / 2.0, params.height / 2.0); | ||||||
|  |    } | ||||||
|  |    p->icons_->SetIconVisible(p->mapCenterIcon_, | ||||||
|  |                              generalSettings.show_map_center().GetValue()); | ||||||
|  | 
 | ||||||
|    QMargins colorTableMargins = context()->color_table_margins(); |    QMargins colorTableMargins = context()->color_table_margins(); | ||||||
|    if (colorTableMargins != p->lastColorTableMargins_ || p->firstRender_) |    if (colorTableMargins != p->lastColorTableMargins_ || p->firstRender_) | ||||||
|    { |    { | ||||||
|  | @ -418,7 +462,6 @@ void OverlayLayer::Render(const QMapLibre::CustomLayerRenderParameters& params) | ||||||
|       p->icons_->SetIconLocation(p->mapLogoIcon_, |       p->icons_->SetIconLocation(p->mapLogoIcon_, | ||||||
|                                  10 + colorTableMargins.left(), |                                  10 + colorTableMargins.left(), | ||||||
|                                  10 + colorTableMargins.bottom()); |                                  10 + colorTableMargins.bottom()); | ||||||
|       p->icons_->FinishIcons(); |  | ||||||
|    } |    } | ||||||
|    p->icons_->SetIconVisible(p->mapLogoIcon_, |    p->icons_->SetIconVisible(p->mapLogoIcon_, | ||||||
|                              generalSettings.show_map_logo().GetValue()); |                              generalSettings.show_map_logo().GetValue()); | ||||||
|  |  | ||||||
|  | @ -58,6 +58,7 @@ public: | ||||||
|       mapboxApiKey_.SetDefault("?"); |       mapboxApiKey_.SetDefault("?"); | ||||||
|       maptilerApiKey_.SetDefault("?"); |       maptilerApiKey_.SetDefault("?"); | ||||||
|       showMapAttribution_.SetDefault(true); |       showMapAttribution_.SetDefault(true); | ||||||
|  |       showMapCenter_.SetDefault(false); | ||||||
|       showMapLogo_.SetDefault(true); |       showMapLogo_.SetDefault(true); | ||||||
|       theme_.SetDefault(defaultThemeValue); |       theme_.SetDefault(defaultThemeValue); | ||||||
|       trackLocation_.SetDefault(false); |       trackLocation_.SetDefault(false); | ||||||
|  | @ -122,6 +123,7 @@ public: | ||||||
|    SettingsVariable<std::string> mapboxApiKey_ {"mapbox_api_key"}; |    SettingsVariable<std::string> mapboxApiKey_ {"mapbox_api_key"}; | ||||||
|    SettingsVariable<std::string> maptilerApiKey_ {"maptiler_api_key"}; |    SettingsVariable<std::string> maptilerApiKey_ {"maptiler_api_key"}; | ||||||
|    SettingsVariable<bool>        showMapAttribution_ {"show_map_attribution"}; |    SettingsVariable<bool>        showMapAttribution_ {"show_map_attribution"}; | ||||||
|  |    SettingsVariable<bool>        showMapCenter_ {"show_map_center"}; | ||||||
|    SettingsVariable<bool>        showMapLogo_ {"show_map_logo"}; |    SettingsVariable<bool>        showMapLogo_ {"show_map_logo"}; | ||||||
|    SettingsVariable<std::string> theme_ {"theme"}; |    SettingsVariable<std::string> theme_ {"theme"}; | ||||||
|    SettingsVariable<bool>        trackLocation_ {"track_location"}; |    SettingsVariable<bool>        trackLocation_ {"track_location"}; | ||||||
|  | @ -147,6 +149,7 @@ GeneralSettings::GeneralSettings() : | ||||||
|                       &p->mapboxApiKey_, |                       &p->mapboxApiKey_, | ||||||
|                       &p->maptilerApiKey_, |                       &p->maptilerApiKey_, | ||||||
|                       &p->showMapAttribution_, |                       &p->showMapAttribution_, | ||||||
|  |                       &p->showMapCenter_, | ||||||
|                       &p->showMapLogo_, |                       &p->showMapLogo_, | ||||||
|                       &p->theme_, |                       &p->theme_, | ||||||
|                       &p->trackLocation_, |                       &p->trackLocation_, | ||||||
|  | @ -240,6 +243,11 @@ SettingsVariable<bool>& GeneralSettings::show_map_attribution() const | ||||||
|    return p->showMapAttribution_; |    return p->showMapAttribution_; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | SettingsVariable<bool>& GeneralSettings::show_map_center() const | ||||||
|  | { | ||||||
|  |    return p->showMapCenter_; | ||||||
|  | } | ||||||
|  | 
 | ||||||
| SettingsVariable<bool>& GeneralSettings::show_map_logo() const | SettingsVariable<bool>& GeneralSettings::show_map_logo() const | ||||||
| { | { | ||||||
|    return p->showMapLogo_; |    return p->showMapLogo_; | ||||||
|  | @ -297,6 +305,7 @@ bool operator==(const GeneralSettings& lhs, const GeneralSettings& rhs) | ||||||
|            lhs.p->mapboxApiKey_ == rhs.p->mapboxApiKey_ && |            lhs.p->mapboxApiKey_ == rhs.p->mapboxApiKey_ && | ||||||
|            lhs.p->maptilerApiKey_ == rhs.p->maptilerApiKey_ && |            lhs.p->maptilerApiKey_ == rhs.p->maptilerApiKey_ && | ||||||
|            lhs.p->showMapAttribution_ == rhs.p->showMapAttribution_ && |            lhs.p->showMapAttribution_ == rhs.p->showMapAttribution_ && | ||||||
|  |            lhs.p->showMapCenter_ == rhs.p->showMapCenter_ && | ||||||
|            lhs.p->showMapLogo_ == rhs.p->showMapLogo_ && |            lhs.p->showMapLogo_ == rhs.p->showMapLogo_ && | ||||||
|            lhs.p->theme_ == rhs.p->theme_ && |            lhs.p->theme_ == rhs.p->theme_ && | ||||||
|            lhs.p->trackLocation_ == rhs.p->trackLocation_ && |            lhs.p->trackLocation_ == rhs.p->trackLocation_ && | ||||||
|  |  | ||||||
|  | @ -41,6 +41,7 @@ public: | ||||||
|    SettingsVariable<std::string>&                mapbox_api_key() const; |    SettingsVariable<std::string>&                mapbox_api_key() const; | ||||||
|    SettingsVariable<std::string>&                maptiler_api_key() const; |    SettingsVariable<std::string>&                maptiler_api_key() const; | ||||||
|    SettingsVariable<bool>&                       show_map_attribution() const; |    SettingsVariable<bool>&                       show_map_attribution() const; | ||||||
|  |    SettingsVariable<bool>&                       show_map_center() const; | ||||||
|    SettingsVariable<bool>&                       show_map_logo() const; |    SettingsVariable<bool>&                       show_map_logo() const; | ||||||
|    SettingsVariable<std::string>&                theme() const; |    SettingsVariable<std::string>&                theme() const; | ||||||
|    SettingsVariable<bool>&                       track_location() const; |    SettingsVariable<bool>&                       track_location() const; | ||||||
|  |  | ||||||
|  | @ -22,6 +22,9 @@ static const std::unordered_map<ImageTexture, TextureInfo> imageTextureInfo_ { | ||||||
|     {"images/compass-24", ":/res/icons/flaticon/compass-24.png"}}, |     {"images/compass-24", ":/res/icons/flaticon/compass-24.png"}}, | ||||||
|    {ImageTexture::Crosshairs24, |    {ImageTexture::Crosshairs24, | ||||||
|     {"images/crosshairs-24", ":/res/textures/images/crosshairs-24.png"}}, |     {"images/crosshairs-24", ":/res/textures/images/crosshairs-24.png"}}, | ||||||
|  |    {ImageTexture::Cursor17, | ||||||
|  |     {"images/cursor-17", ":/res/textures/images/cursor-17.png"}}, | ||||||
|  |    {ImageTexture::Dot3, {"images/dot-3", ":/res/textures/images/dot-3.png"}}, | ||||||
|    {ImageTexture::MapboxLogo, |    {ImageTexture::MapboxLogo, | ||||||
|     {"images/mapbox-logo", ":/res/textures/images/mapbox-logo.svg"}}, |     {"images/mapbox-logo", ":/res/textures/images/mapbox-logo.svg"}}, | ||||||
|    {ImageTexture::MapTilerLogo, |    {ImageTexture::MapTilerLogo, | ||||||
|  |  | ||||||
|  | @ -16,6 +16,8 @@ enum class ImageTexture | ||||||
|    CardinalPoint24, |    CardinalPoint24, | ||||||
|    Compass24, |    Compass24, | ||||||
|    Crosshairs24, |    Crosshairs24, | ||||||
|  |    Cursor17, | ||||||
|  |    Dot3, | ||||||
|    MapboxLogo, |    MapboxLogo, | ||||||
|    MapTilerLogo |    MapTilerLogo | ||||||
| }; | }; | ||||||
|  |  | ||||||
|  | @ -135,6 +135,7 @@ public: | ||||||
|           &defaultTimeZone_, |           &defaultTimeZone_, | ||||||
|           &antiAliasingEnabled_, |           &antiAliasingEnabled_, | ||||||
|           &showMapAttribution_, |           &showMapAttribution_, | ||||||
|  |           &showMapCenter_, | ||||||
|           &showMapLogo_, |           &showMapLogo_, | ||||||
|           &updateNotificationsEnabled_, |           &updateNotificationsEnabled_, | ||||||
|           &debugEnabled_, |           &debugEnabled_, | ||||||
|  | @ -233,6 +234,7 @@ public: | ||||||
|    settings::SettingsInterface<std::string>  theme_ {}; |    settings::SettingsInterface<std::string>  theme_ {}; | ||||||
|    settings::SettingsInterface<bool>         antiAliasingEnabled_ {}; |    settings::SettingsInterface<bool>         antiAliasingEnabled_ {}; | ||||||
|    settings::SettingsInterface<bool>         showMapAttribution_ {}; |    settings::SettingsInterface<bool>         showMapAttribution_ {}; | ||||||
|  |    settings::SettingsInterface<bool>         showMapCenter_ {}; | ||||||
|    settings::SettingsInterface<bool>         showMapLogo_ {}; |    settings::SettingsInterface<bool>         showMapLogo_ {}; | ||||||
|    settings::SettingsInterface<bool>         updateNotificationsEnabled_ {}; |    settings::SettingsInterface<bool>         updateNotificationsEnabled_ {}; | ||||||
|    settings::SettingsInterface<bool>         debugEnabled_ {}; |    settings::SettingsInterface<bool>         debugEnabled_ {}; | ||||||
|  | @ -666,6 +668,9 @@ void SettingsDialogImpl::SetupGeneralTab() | ||||||
|       generalSettings.show_map_attribution()); |       generalSettings.show_map_attribution()); | ||||||
|    showMapAttribution_.SetEditWidget(self_->ui->showMapAttributionCheckBox); |    showMapAttribution_.SetEditWidget(self_->ui->showMapAttributionCheckBox); | ||||||
| 
 | 
 | ||||||
|  |    showMapCenter_.SetSettingsVariable(generalSettings.show_map_center()); | ||||||
|  |    showMapCenter_.SetEditWidget(self_->ui->showMapCenterCheckBox); | ||||||
|  | 
 | ||||||
|    showMapLogo_.SetSettingsVariable(generalSettings.show_map_logo()); |    showMapLogo_.SetSettingsVariable(generalSettings.show_map_logo()); | ||||||
|    showMapLogo_.SetEditWidget(self_->ui->showMapLogoCheckBox); |    showMapLogo_.SetEditWidget(self_->ui->showMapLogoCheckBox); | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -118,302 +118,325 @@ | ||||||
|          <widget class="QWidget" name="general"> |          <widget class="QWidget" name="general"> | ||||||
|           <layout class="QVBoxLayout" name="verticalLayout_2"> |           <layout class="QVBoxLayout" name="verticalLayout_2"> | ||||||
|            <item> |            <item> | ||||||
|             <widget class="QFrame" name="frame_2"> |             <widget class="QScrollArea" name="scrollArea_2"> | ||||||
|              <property name="frameShape"> |              <property name="widgetResizable"> | ||||||
|               <enum>QFrame::StyledPanel</enum> |               <bool>true</bool> | ||||||
|              </property> |              </property> | ||||||
|              <property name="frameShadow"> |              <widget class="QWidget" name="scrollAreaWidgetContents_2"> | ||||||
|               <enum>QFrame::Raised</enum> |               <property name="geometry"> | ||||||
|              </property> |                <rect> | ||||||
|              <layout class="QGridLayout" name="gridLayout_4"> |                 <x>0</x> | ||||||
|               <property name="leftMargin"> |                 <y>0</y> | ||||||
|                <number>0</number> |                 <width>513</width> | ||||||
|  |                 <height>454</height> | ||||||
|  |                </rect> | ||||||
|               </property> |               </property> | ||||||
|               <property name="topMargin"> |               <layout class="QVBoxLayout" name="verticalLayout"> | ||||||
|                <number>0</number> |                <item> | ||||||
|               </property> |                 <widget class="QFrame" name="frame_2"> | ||||||
|               <property name="rightMargin"> |                  <property name="frameShape"> | ||||||
|                <number>0</number> |                   <enum>QFrame::NoFrame</enum> | ||||||
|               </property> |                  </property> | ||||||
|               <property name="bottomMargin"> |                  <layout class="QGridLayout" name="gridLayout_4"> | ||||||
|                <number>0</number> |                   <property name="leftMargin"> | ||||||
|               </property> |                    <number>0</number> | ||||||
|               <item row="8" column="0"> |                   </property> | ||||||
|                <widget class="QLabel" name="defaultAlertActionLabel"> |                   <property name="topMargin"> | ||||||
|                 <property name="text"> |                    <number>0</number> | ||||||
|                  <string>Default Alert Action</string> |                   </property> | ||||||
|                 </property> |                   <property name="rightMargin"> | ||||||
|                </widget> |                    <number>0</number> | ||||||
|               </item> |                   </property> | ||||||
|               <item row="0" column="2"> |                   <property name="bottomMargin"> | ||||||
|                <widget class="QComboBox" name="themeComboBox"/> |                    <number>0</number> | ||||||
|               </item> |                   </property> | ||||||
|               <item row="0" column="4"> |                   <item row="1" column="0"> | ||||||
|                <widget class="QToolButton" name="resetThemeButton"> |                    <widget class="QLabel" name="label"> | ||||||
|                 <property name="text"> |                     <property name="text"> | ||||||
|                  <string>...</string> |                      <string>Default Radar Site</string> | ||||||
|                 </property> |                     </property> | ||||||
|                 <property name="icon"> |                    </widget> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                   </item> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   <item row="10" column="0"> | ||||||
|                 </property> |                    <widget class="QLabel" name="label_21"> | ||||||
|                </widget> |                     <property name="text"> | ||||||
|               </item> |                      <string>Default Time Zone</string> | ||||||
|               <item row="8" column="2"> |                     </property> | ||||||
|                <widget class="QComboBox" name="defaultAlertActionComboBox"/> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="6" column="2"> |                   <item row="5" column="0"> | ||||||
|                <widget class="QLineEdit" name="mapboxApiKeyLineEdit"> |                    <widget class="QLabel" name="label_7"> | ||||||
|                 <property name="echoMode"> |                     <property name="text"> | ||||||
|                  <enum>QLineEdit::Password</enum> |                      <string>Map Provider</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="10" column="0"> |                   <item row="0" column="4"> | ||||||
|                <widget class="QLabel" name="label_21"> |                    <widget class="QToolButton" name="resetThemeButton"> | ||||||
|                 <property name="text"> |                     <property name="text"> | ||||||
|                  <string>Default Time Zone</string> |                      <string>...</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                     <property name="icon"> | ||||||
|               </item> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|               <item row="2" column="0"> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                <widget class="QLabel" name="label_2"> |                     </property> | ||||||
|                 <property name="text"> |                    </widget> | ||||||
|                  <string>Grid Width</string> |                   </item> | ||||||
|                 </property> |                   <item row="8" column="4"> | ||||||
|                </widget> |                    <widget class="QToolButton" name="resetDefaultAlertActionButton"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="0" column="0"> |                      <string>...</string> | ||||||
|                <widget class="QLabel" name="label_5"> |                     </property> | ||||||
|                 <property name="text"> |                     <property name="icon"> | ||||||
|                  <string>Theme</string> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                 </property> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                </widget> |                     </property> | ||||||
|               </item> |                    </widget> | ||||||
|               <item row="5" column="0"> |                   </item> | ||||||
|                <widget class="QLabel" name="label_7"> |                   <item row="9" column="2"> | ||||||
|                 <property name="text"> |                    <widget class="QComboBox" name="clockFormatComboBox"/> | ||||||
|                  <string>Map Provider</string> |                   </item> | ||||||
|                 </property> |                   <item row="6" column="0"> | ||||||
|                </widget> |                    <widget class="QLabel" name="label_4"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="7" column="0"> |                      <string>Mapbox API Key</string> | ||||||
|                <widget class="QLabel" name="label_6"> |                     </property> | ||||||
|                 <property name="text"> |                    </widget> | ||||||
|                  <string>MapTiler API Key</string> |                   </item> | ||||||
|                 </property> |                   <item row="2" column="0"> | ||||||
|                </widget> |                    <widget class="QLabel" name="label_2"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="3" column="4"> |                      <string>Grid Width</string> | ||||||
|                <widget class="QToolButton" name="resetGridHeightButton"> |                     </property> | ||||||
|                 <property name="text"> |                    </widget> | ||||||
|                  <string>...</string> |                   </item> | ||||||
|                 </property> |                   <item row="7" column="0"> | ||||||
|                 <property name="icon"> |                    <widget class="QLabel" name="label_6"> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                     <property name="text"> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                      <string>MapTiler API Key</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="5" column="2"> |                   <item row="10" column="4"> | ||||||
|                <widget class="QComboBox" name="mapProviderComboBox"/> |                    <widget class="QToolButton" name="resetDefaultTimeZoneButton"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="10" column="2"> |                      <string>...</string> | ||||||
|                <widget class="QComboBox" name="defaultTimeZoneComboBox"/> |                     </property> | ||||||
|               </item> |                     <property name="icon"> | ||||||
|               <item row="7" column="4"> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                <widget class="QToolButton" name="resetMapTilerApiKeyButton"> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 <property name="text"> |                     </property> | ||||||
|                  <string>...</string> |                    </widget> | ||||||
|                 </property> |                   </item> | ||||||
|                 <property name="icon"> |                   <item row="8" column="2"> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                    <widget class="QComboBox" name="defaultAlertActionComboBox"/> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   </item> | ||||||
|                 </property> |                   <item row="7" column="4"> | ||||||
|                </widget> |                    <widget class="QToolButton" name="resetMapTilerApiKeyButton"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="5" column="4"> |                      <string>...</string> | ||||||
|                <widget class="QToolButton" name="resetMapProviderButton"> |                     </property> | ||||||
|                 <property name="text"> |                     <property name="icon"> | ||||||
|                  <string>...</string> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                 </property> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 <property name="icon"> |                     </property> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                    </widget> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   </item> | ||||||
|                 </property> |                   <item row="3" column="4"> | ||||||
|                </widget> |                    <widget class="QToolButton" name="resetGridHeightButton"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="2" column="4"> |                      <string>...</string> | ||||||
|                <widget class="QToolButton" name="resetGridWidthButton"> |                     </property> | ||||||
|                 <property name="text"> |                     <property name="icon"> | ||||||
|                  <string>...</string> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                 </property> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 <property name="icon"> |                     </property> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                    </widget> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   </item> | ||||||
|                 </property> |                   <item row="1" column="2"> | ||||||
|                </widget> |                    <widget class="QComboBox" name="radarSiteComboBox"/> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="9" column="0"> |                   <item row="1" column="4"> | ||||||
|                <widget class="QLabel" name="label_20"> |                    <widget class="QToolButton" name="resetRadarSiteButton"> | ||||||
|                 <property name="text"> |                     <property name="text"> | ||||||
|                  <string>Clock Format</string> |                      <string>...</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                     <property name="icon"> | ||||||
|               </item> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|               <item row="9" column="4"> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                <widget class="QToolButton" name="resetClockFormatButton"> |                     </property> | ||||||
|                 <property name="text"> |                    </widget> | ||||||
|                  <string>...</string> |                   </item> | ||||||
|                 </property> |                   <item row="6" column="2"> | ||||||
|                 <property name="icon"> |                    <widget class="QLineEdit" name="mapboxApiKeyLineEdit"> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                     <property name="echoMode"> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                      <enum>QLineEdit::Password</enum> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="2" column="2"> |                   <item row="0" column="0"> | ||||||
|                <widget class="QSpinBox" name="gridWidthSpinBox"/> |                    <widget class="QLabel" name="label_5"> | ||||||
|               </item> |                     <property name="text"> | ||||||
|               <item row="9" column="2"> |                      <string>Theme</string> | ||||||
|                <widget class="QComboBox" name="clockFormatComboBox"/> |                     </property> | ||||||
|               </item> |                    </widget> | ||||||
|               <item row="1" column="4"> |                   </item> | ||||||
|                <widget class="QToolButton" name="resetRadarSiteButton"> |                   <item row="0" column="2"> | ||||||
|                 <property name="text"> |                    <widget class="QComboBox" name="themeComboBox"/> | ||||||
|                  <string>...</string> |                   </item> | ||||||
|                 </property> |                   <item row="10" column="2"> | ||||||
|                 <property name="icon"> |                    <widget class="QComboBox" name="defaultTimeZoneComboBox"/> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                   </item> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   <item row="1" column="3"> | ||||||
|                 </property> |                    <widget class="QToolButton" name="radarSiteSelectButton"> | ||||||
|                </widget> |                     <property name="text"> | ||||||
|               </item> |                      <string>...</string> | ||||||
|               <item row="1" column="2"> |                     </property> | ||||||
|                <widget class="QComboBox" name="radarSiteComboBox"/> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="1" column="0"> |                   <item row="7" column="2"> | ||||||
|                <widget class="QLabel" name="label"> |                    <widget class="QLineEdit" name="mapTilerApiKeyLineEdit"> | ||||||
|                 <property name="text"> |                     <property name="echoMode"> | ||||||
|                  <string>Default Radar Site</string> |                      <enum>QLineEdit::Password</enum> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="6" column="0"> |                   <item row="8" column="0"> | ||||||
|                <widget class="QLabel" name="label_4"> |                    <widget class="QLabel" name="defaultAlertActionLabel"> | ||||||
|                 <property name="text"> |                     <property name="text"> | ||||||
|                  <string>Mapbox API Key</string> |                      <string>Default Alert Action</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="6" column="4"> |                   <item row="2" column="4"> | ||||||
|                <widget class="QToolButton" name="resetMapboxApiKeyButton"> |                    <widget class="QToolButton" name="resetGridWidthButton"> | ||||||
|                 <property name="text"> |                     <property name="text"> | ||||||
|                  <string>...</string> |                      <string>...</string> | ||||||
|                 </property> |                     </property> | ||||||
|                 <property name="icon"> |                     <property name="icon"> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="3" column="0"> |                   <item row="5" column="2"> | ||||||
|                <widget class="QLabel" name="label_3"> |                    <widget class="QComboBox" name="mapProviderComboBox"/> | ||||||
|                 <property name="text"> |                   </item> | ||||||
|                  <string>Grid Height</string> |                   <item row="5" column="4"> | ||||||
|                 </property> |                    <widget class="QToolButton" name="resetMapProviderButton"> | ||||||
|                </widget> |                     <property name="text"> | ||||||
|               </item> |                      <string>...</string> | ||||||
|               <item row="8" column="4"> |                     </property> | ||||||
|                <widget class="QToolButton" name="resetDefaultAlertActionButton"> |                     <property name="icon"> | ||||||
|                 <property name="text"> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                  <string>...</string> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 </property> |                     </property> | ||||||
|                 <property name="icon"> |                    </widget> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                   </item> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   <item row="6" column="4"> | ||||||
|                 </property> |                    <widget class="QToolButton" name="resetMapboxApiKeyButton"> | ||||||
|                </widget> |                     <property name="text"> | ||||||
|               </item> |                      <string>...</string> | ||||||
|               <item row="1" column="3"> |                     </property> | ||||||
|                <widget class="QToolButton" name="radarSiteSelectButton"> |                     <property name="icon"> | ||||||
|                 <property name="text"> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|                  <string>...</string> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                    </widget> | ||||||
|               </item> |                   </item> | ||||||
|               <item row="7" column="2"> |                   <item row="9" column="4"> | ||||||
|                <widget class="QLineEdit" name="mapTilerApiKeyLineEdit"> |                    <widget class="QToolButton" name="resetClockFormatButton"> | ||||||
|                 <property name="echoMode"> |                     <property name="text"> | ||||||
|                  <enum>QLineEdit::Password</enum> |                      <string>...</string> | ||||||
|                 </property> |                     </property> | ||||||
|                </widget> |                     <property name="icon"> | ||||||
|               </item> |                      <iconset resource="../../../../scwx-qt.qrc"> | ||||||
|               <item row="3" column="2"> |                       <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> | ||||||
|                <widget class="QSpinBox" name="gridHeightSpinBox"/> |                     </property> | ||||||
|               </item> |                    </widget> | ||||||
|               <item row="10" column="4"> |                   </item> | ||||||
|                <widget class="QToolButton" name="resetDefaultTimeZoneButton"> |                   <item row="3" column="2"> | ||||||
|                 <property name="text"> |                    <widget class="QSpinBox" name="gridHeightSpinBox"/> | ||||||
|                  <string>...</string> |                   </item> | ||||||
|                 </property> |                   <item row="2" column="2"> | ||||||
|                 <property name="icon"> |                    <widget class="QSpinBox" name="gridWidthSpinBox"/> | ||||||
|                  <iconset resource="../../../../scwx-qt.qrc"> |                   </item> | ||||||
|                   <normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</normaloff>:/res/icons/font-awesome-6/rotate-left-solid.svg</iconset> |                   <item row="9" column="0"> | ||||||
|                 </property> |                    <widget class="QLabel" name="label_20"> | ||||||
|                </widget> |                     <property name="text"> | ||||||
|               </item> |                      <string>Clock Format</string> | ||||||
|              </layout> |                     </property> | ||||||
|  |                    </widget> | ||||||
|  |                   </item> | ||||||
|  |                   <item row="3" column="0"> | ||||||
|  |                    <widget class="QLabel" name="label_3"> | ||||||
|  |                     <property name="text"> | ||||||
|  |                      <string>Grid Height</string> | ||||||
|  |                     </property> | ||||||
|  |                    </widget> | ||||||
|  |                   </item> | ||||||
|  |                  </layout> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="antiAliasingEnabledCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Anti-Aliasing Enabled</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="showMapAttributionCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Show Map Attribution</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="showMapCenterCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Show Map Center</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="showMapLogoCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Show Map Logo</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="enableUpdateNotificationsCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Update Notifications Enabled</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <widget class="QCheckBox" name="debugEnabledCheckBox"> | ||||||
|  |                  <property name="text"> | ||||||
|  |                   <string>Debug Enabled</string> | ||||||
|  |                  </property> | ||||||
|  |                 </widget> | ||||||
|  |                </item> | ||||||
|  |                <item> | ||||||
|  |                 <spacer name="verticalSpacer"> | ||||||
|  |                  <property name="orientation"> | ||||||
|  |                   <enum>Qt::Vertical</enum> | ||||||
|  |                  </property> | ||||||
|  |                  <property name="sizeHint" stdset="0"> | ||||||
|  |                   <size> | ||||||
|  |                    <width>20</width> | ||||||
|  |                    <height>40</height> | ||||||
|  |                   </size> | ||||||
|  |                  </property> | ||||||
|  |                 </spacer> | ||||||
|  |                </item> | ||||||
|  |               </layout> | ||||||
|  |              </widget> | ||||||
|             </widget> |             </widget> | ||||||
|            </item> |            </item> | ||||||
|            <item> |  | ||||||
|             <widget class="QCheckBox" name="antiAliasingEnabledCheckBox"> |  | ||||||
|              <property name="text"> |  | ||||||
|               <string>Anti-Aliasing Enabled</string> |  | ||||||
|              </property> |  | ||||||
|             </widget> |  | ||||||
|            </item> |  | ||||||
|            <item> |  | ||||||
|             <widget class="QCheckBox" name="showMapAttributionCheckBox"> |  | ||||||
|              <property name="text"> |  | ||||||
|               <string>Show Map Attribution</string> |  | ||||||
|              </property> |  | ||||||
|             </widget> |  | ||||||
|            </item> |  | ||||||
|            <item> |  | ||||||
|             <widget class="QCheckBox" name="showMapLogoCheckBox"> |  | ||||||
|              <property name="text"> |  | ||||||
|               <string>Show Map Logo</string> |  | ||||||
|              </property> |  | ||||||
|             </widget> |  | ||||||
|            </item> |  | ||||||
|            <item> |  | ||||||
|             <widget class="QCheckBox" name="enableUpdateNotificationsCheckBox"> |  | ||||||
|              <property name="text"> |  | ||||||
|               <string>Update Notifications Enabled</string> |  | ||||||
|              </property> |  | ||||||
|             </widget> |  | ||||||
|            </item> |  | ||||||
|            <item> |  | ||||||
|             <widget class="QCheckBox" name="debugEnabledCheckBox"> |  | ||||||
|              <property name="text"> |  | ||||||
|               <string>Debug Enabled</string> |  | ||||||
|              </property> |  | ||||||
|             </widget> |  | ||||||
|            </item> |  | ||||||
|            <item> |  | ||||||
|             <spacer name="verticalSpacer"> |  | ||||||
|              <property name="orientation"> |  | ||||||
|               <enum>Qt::Vertical</enum> |  | ||||||
|              </property> |  | ||||||
|              <property name="sizeHint" stdset="0"> |  | ||||||
|               <size> |  | ||||||
|                <width>20</width> |  | ||||||
|                <height>40</height> |  | ||||||
|               </size> |  | ||||||
|              </property> |  | ||||||
|             </spacer> |  | ||||||
|            </item> |  | ||||||
|           </layout> |           </layout> | ||||||
|          </widget> |          </widget> | ||||||
|          <widget class="QWidget" name="palettes"> |          <widget class="QWidget" name="palettes"> | ||||||
|  | @ -438,8 +461,8 @@ | ||||||
|                    <rect> |                    <rect> | ||||||
|                     <x>0</x> |                     <x>0</x> | ||||||
|                     <y>0</y> |                     <y>0</y> | ||||||
|                     <width>498</width> |                     <width>63</width> | ||||||
|                     <height>383</height> |                     <height>18</height> | ||||||
|                    </rect> |                    </rect> | ||||||
|                   </property> |                   </property> | ||||||
|                   <layout class="QGridLayout" name="gridLayout_3"> |                   <layout class="QGridLayout" name="gridLayout_3"> | ||||||
|  |  | ||||||
|  | @ -1 +1 @@ | ||||||
| Subproject commit 260b340030487b01ce9aa37135d949008c972f27 | Subproject commit ab32df5b0731d70aa5b977453c9aa4786eb0bd3f | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat