| 
									
										
										
										
											2019-02-11 18:53:06 +01:00
										 |  |  | // SPDX-License-Identifier: GPL-2.0
 | 
					
						
							|  |  |  | import QtQuick 2.11 | 
					
						
							|  |  |  | import QtQuick.Controls 2.4 | 
					
						
							|  |  |  | import QtQuick.Layouts 1.11 | 
					
						
							| 
									
										
										
										
											2020-12-19 14:57:19 -08:00
										 |  |  | import org.kde.kirigami 2.4 as Kirigami | 
					
						
							| 
									
										
										
										
											2019-02-11 18:53:06 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | CheckBox { | 
					
						
							| 
									
										
										
										
											2020-12-19 14:57:19 -08:00
										 |  |  | 	id: cb | 
					
						
							|  |  |  | 	indicator: Rectangle { | 
					
						
							|  |  |  | 		implicitWidth: Kirigami.Units.gridUnit | 
					
						
							|  |  |  | 		implicitHeight: Kirigami.Units.gridUnit | 
					
						
							|  |  |  | 		x: cb.leftPadding | 
					
						
							|  |  |  | 		y: parent.height / 2 - height / 2 | 
					
						
							| 
									
										
										
										
											2020-12-30 18:09:39 -08:00
										 |  |  | 		radius: 4 | 
					
						
							|  |  |  | 		border.color: cb.down ? subsurfaceTheme.darkerPrimaryColor : subsurfaceTheme.primaryColor | 
					
						
							|  |  |  | 		border.width: 2 | 
					
						
							| 
									
										
										
										
											2020-12-19 14:57:19 -08:00
										 |  |  | 		color: subsurfaceTheme.backgroundColor | 
					
						
							|  |  |  | 		Rectangle { | 
					
						
							|  |  |  | 			width: parent.width / 2 | 
					
						
							|  |  |  | 			height: width | 
					
						
							|  |  |  | 			x: width / 2 | 
					
						
							|  |  |  | 			y: width / 2 | 
					
						
							| 
									
										
										
										
											2020-12-30 18:09:39 -08:00
										 |  |  | 			radius: 3 | 
					
						
							|  |  |  | 			color: cb.down ? subsurfaceTheme.darkerPrimaryColor : subsurfaceTheme.primaryColor | 
					
						
							| 
									
										
										
										
											2020-12-19 14:57:19 -08:00
										 |  |  | 			visible: cb.checked | 
					
						
							|  |  |  | 		} | 
					
						
							|  |  |  | 	} | 
					
						
							|  |  |  | 	contentItem: Text { | 
					
						
							|  |  |  | 		color: subsurfaceTheme.textColor | 
					
						
							|  |  |  | 		font.pointSize: subsurfaceTheme.regularPointSize | 
					
						
							|  |  |  | 		text: cb.text | 
					
						
							|  |  |  | 		leftPadding: cb.indicator.width + cb.spacing | 
					
						
							|  |  |  | 	} | 
					
						
							| 
									
										
										
										
											2019-02-11 18:53:06 +01:00
										 |  |  | } |