Make flow ribbons themeable

This commit is contained in:
luisangelsm
2026-03-21 20:45:23 +01:00
parent 5fbd5bc185
commit f65fd08e65
13 changed files with 201 additions and 32 deletions

View File

@ -179,6 +179,10 @@ protected:
QColor backgroundColor;
QColor textColor;
QImage readRibbonImage;
QImage readingRibbonImage;
bool ribbonTexturesDirty = false;
/*** System info ***/
float viewRotate;
@ -202,6 +206,8 @@ protected:
// Helper methods
QRhiTexture *createTextureFromImage(QRhiCommandBuffer *cb, const QImage &image);
void removeCachedShaderBindings(QRhiTexture *texture);
void syncRibbonTextures(QRhiResourceUpdateBatch *batch);
void updateUniformBuffer(QRhiCommandBuffer *cb, const UniformData &data);
void prepareMarkInstanceData(const YACReader3DImageRHI &image, QVector<float> &data);
void ensureUniformBufferCapacity(int requiredSlots);
@ -260,6 +266,9 @@ public slots:
void setBackgroundColor(const QColor &color);
void setTextColor(const QColor &color);
// Ribbon image setters (for themed SVG rasterized images)
void setRibbonImages(const QImage &readImage, const QImage &readingImage);
virtual void updateImageData() = 0;
void reset();