MCPcopy Create free account
hub / github.com/KDE/labplot / setImages

Method setImages

src/frontend/dockwidgets/ImageDock.cpp:95–129  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

93}
94
95void ImageDock::setImages(QList<Image*> list) {
96 CONDITIONAL_LOCK_RETURN;
97 m_imageList = list;
98 m_image = list.first();
99 setAspects(list);
100
101 QList<Line*> lines;
102 for (auto* image : m_imageList)
103 lines << image->borderLine();
104
105 borderLineWidget->setLines(lines);
106
107 // show the properties of the first image
108 this->load();
109
110 // init connections
111 // General
112 connect(m_image, &Image::fileNameChanged, this, &ImageDock::imageFileNameChanged);
113 connect(m_image, &Image::embeddedChanged, this, &ImageDock::imageEmbeddedChanged);
114 connect(m_image, &Image::opacityChanged, this, &ImageDock::imageOpacityChanged);
115 connect(m_image, &Image::lockChanged, this, &ImageDock::imageLockChanged);
116
117 // Size
118 connect(m_image, &Image::widthChanged, this, &ImageDock::imageWidthChanged);
119 connect(m_image, &Image::heightChanged, this, &ImageDock::imageHeightChanged);
120 connect(m_image, &Image::keepRatioChanged, this, &ImageDock::imageKeepRatioChanged);
121
122 // Position
123 connect(m_image, &Image::positionChanged, this, &ImageDock::imagePositionChanged);
124 connect(m_image, &Image::positionLogicalChanged, this, &ImageDock::imagePositionLogicalChanged);
125 connect(m_image, &Image::coordinateBindingEnabledChanged, this, &ImageDock::imageCoordinateBindingEnabledChanged);
126 connect(m_image, &Image::horizontalAlignmentChanged, this, &ImageDock::imageHorizontalAlignmentChanged);
127 connect(m_image, &Image::verticalAlignmentChanged, this, &ImageDock::imageVerticalAlignmentChanged);
128 connect(m_image, &Image::rotationAngleChanged, this, &ImageDock::imageRotationAngleChanged);
129}
130
131void ImageDock::updateUnits() {
132 const KConfigGroup group = Settings::group(QStringLiteral("Settings_General"));

Callers 15

linearMappingMethod · 0.45
logarithmic10XMappingMethod · 0.45
logarithmic10YMappingMethod · 0.45
referenceMoveMethod · 0.45
referenceMoveKeyPressMethod · 0.45
curvePointMoveMethod · 0.45

Calls 3

loadMethod · 0.95
setLinesMethod · 0.80
borderLineMethod · 0.45

Tested by 15

linearMappingMethod · 0.36
logarithmic10XMappingMethod · 0.36
logarithmic10YMappingMethod · 0.36
referenceMoveMethod · 0.36
referenceMoveKeyPressMethod · 0.36
curvePointMoveMethod · 0.36
selectReferencePointMethod · 0.36