
from qgis.core import (
	QgsLayoutSize,
	QgsUnitTypes,
	QgsLayoutPoint,
)
def fletch_canvas(self):
	if self.radioButton_6.isChecked():
		values_page = 'A4'
	else:
		values_page = 'A3'
	if self.radioButton_7.isChecked():
		page_rotate = 'Portrait' 
	else:
		page_rotate = 'Landscape'

	if page_rotate == 'Portrait':
		if values_page == 'A4':
			self.template_parameters['Carte_size'] = QgsLayoutSize(200.0,200, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_locals'] = QgsLayoutPoint(6, 6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_rotate'] = 0
			self.template_parameters['Carte_2_size'] = QgsLayoutSize(80.0,80, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_locals'] = QgsLayoutPoint(126, 210, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_rotate'] = 0
			self.template_parameters['Legande_size'] = QgsLayoutSize(86.0,86, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_locals'] = QgsLayoutPoint(6, 208, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_rotate'] = 0
			self.template_parameters['Arrow_size'] = QgsLayoutSize(14.285714285714286,14, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_locals'] = QgsLayoutPoint(189, 20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_rotate'] = 0
			self.template_parameters['Echelle_size'] = QgsLayoutSize(51.42857142857143,7, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_locals'] = QgsLayoutPoint(9, 197, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_rotate'] = 0
			self.template_parameters['Logo_size'] = QgsLayoutSize(45.714285714285715,11, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_locals'] = QgsLayoutPoint(3, 3, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_rotate'] = 0
			self.template_parameters['Titre_size'] = QgsLayoutSize(154.28571428571428,11, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_locals'] = QgsLayoutPoint(51, 3, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_rotate'] = 0
			self.template_parameters['Credit_size'] = QgsLayoutSize(51.42857142857143,6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_locals'] = QgsLayoutPoint(151, 210, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_rotate'] = 0
			self.template_parameters['Source_size'] = QgsLayoutSize(51.42857142857143,6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_locals'] = QgsLayoutPoint(229, 197, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_rotate'] = 0
			self.template_parameters['Sous_titre_size'] = QgsLayoutSize(125.71428571428571,14, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_locals'] = QgsLayoutPoint(60, 20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_rotate'] = 0
			self.template_parameters['Echelle_2_size'] = QgsLayoutSize(51.42857142857143,13, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_locals'] = QgsLayoutPoint(9, 184, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_rotate'] = 0
			self.template_parameters['Logo_2_size'] = QgsLayoutSize(28.571428571428573,29, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_locals'] = QgsLayoutPoint(9, 151, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_rotate'] = 0
		if values_page == 'A3':
			self.template_parameters['Carte_size'] = QgsLayoutSize(282,282, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_locals'] = QgsLayoutPoint(8, 8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_rotate'] = 0
			self.template_parameters['Carte_2_size'] = QgsLayoutSize(113,113, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_locals'] = QgsLayoutPoint(178, 296, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_rotate'] = 0
			self.template_parameters['Legande_size'] = QgsLayoutSize(121,121, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_locals'] = QgsLayoutPoint(8, 293, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_rotate'] = 0
			self.template_parameters['Arrow_size'] = QgsLayoutSize(20,20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_locals'] = QgsLayoutPoint(267, 28, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_rotate'] = 0
			self.template_parameters['Echelle_size'] = QgsLayoutSize(73,10, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_locals'] = QgsLayoutPoint(13, 278, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_rotate'] = 0
			self.template_parameters['Logo_size'] = QgsLayoutSize(64,16, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_locals'] = QgsLayoutPoint(4, 4, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_rotate'] = 0
			self.template_parameters['Titre_size'] = QgsLayoutSize(218,16, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_locals'] = QgsLayoutPoint(72, 4, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_rotate'] = 0
			self.template_parameters['Credit_size'] = QgsLayoutSize(73,8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_locals'] = QgsLayoutPoint(213, 296, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_rotate'] = 0
			self.template_parameters['Source_size'] = QgsLayoutSize(73,8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_locals'] = QgsLayoutPoint(323, 278, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_rotate'] = 0
			self.template_parameters['Sous_titre_size'] = QgsLayoutSize(177,20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_locals'] = QgsLayoutPoint(85, 28, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_rotate'] = 0
			self.template_parameters['Echelle_2_size'] = QgsLayoutSize(73,18, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_locals'] = QgsLayoutPoint(13, 259, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_rotate'] = 0
			self.template_parameters['Logo_2_size'] = QgsLayoutSize(40,40, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_locals'] = QgsLayoutPoint(13, 213, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_rotate'] = 0
	if page_rotate == 'Landscape':
		if values_page == 'A4':
			self.template_parameters['Carte_size'] = QgsLayoutSize(200.0,200, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_locals'] = QgsLayoutPoint(6, 6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_rotate'] = 0
			self.template_parameters['Carte_2_size'] = QgsLayoutSize(85.71428571428571,69, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_locals'] = QgsLayoutPoint(209, 3, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_rotate'] = 0
			self.template_parameters['Legande_size'] = QgsLayoutSize(85.71428571428571,131, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_locals'] = QgsLayoutPoint(209, 74, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_rotate'] = 0
			self.template_parameters['Arrow_size'] = QgsLayoutSize(14.285714285714286,14, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_locals'] = QgsLayoutPoint(189, 20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_rotate'] = 0
			self.template_parameters['Echelle_size'] = QgsLayoutSize(51.42857142857143,7, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_locals'] = QgsLayoutPoint(9, 197, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_rotate'] = 0
			self.template_parameters['Logo_size'] = QgsLayoutSize(45.714285714285715,11, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_locals'] = QgsLayoutPoint(3, 3, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_rotate'] = 0
			self.template_parameters['Titre_size'] = QgsLayoutSize(154.28571428571428,11, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_locals'] = QgsLayoutPoint(51, 3, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_rotate'] = 0
			self.template_parameters['Credit_size'] = QgsLayoutSize(51.42857142857143,6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_locals'] = QgsLayoutPoint(151, 197, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_rotate'] = 0
			self.template_parameters['Source_size'] = QgsLayoutSize(51.42857142857143,6, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_locals'] = QgsLayoutPoint(229, 197, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_rotate'] = 0
			self.template_parameters['Sous_titre_size'] = QgsLayoutSize(125.71428571428571,14, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_locals'] = QgsLayoutPoint(60, 20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_rotate'] = 0
			self.template_parameters['Echelle_2_size'] = QgsLayoutSize(51.42857142857143,13, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_locals'] = QgsLayoutPoint(9, 184, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_rotate'] = 0
			self.template_parameters['Logo_2_size'] = QgsLayoutSize(28.571428571428573,29, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_locals'] = QgsLayoutPoint(9, 151, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_rotate'] = 0
		if values_page == 'A3':
			self.template_parameters['Carte_size'] = QgsLayoutSize(282,282, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_locals'] = QgsLayoutPoint(8, 8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_rotate'] = 0
			self.template_parameters['Carte_2_size'] = QgsLayoutSize(121,97, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_locals'] = QgsLayoutPoint(294, 4, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Carte_2_rotate'] = 0
			self.template_parameters['Legande_size'] = QgsLayoutSize(121,185, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_locals'] = QgsLayoutPoint(294, 105, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Legande_rotate'] = 0
			self.template_parameters['Arrow_size'] = QgsLayoutSize(20,20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_locals'] = QgsLayoutPoint(266, 28, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Arrow_rotate'] = 0
			self.template_parameters['Echelle_size'] = QgsLayoutSize(73,10, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_locals'] = QgsLayoutPoint(12, 278, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_rotate'] = 0
			self.template_parameters['Logo_size'] = QgsLayoutSize(64,16, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_locals'] = QgsLayoutPoint(4, 4, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_rotate'] = 0
			self.template_parameters['Titre_size'] = QgsLayoutSize(218,16, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_locals'] = QgsLayoutPoint(73, 4, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Titre_rotate'] = 0
			self.template_parameters['Credit_size'] = QgsLayoutSize(73,8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_locals'] = QgsLayoutPoint(214, 278, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Credit_rotate'] = 0
			self.template_parameters['Source_size'] = QgsLayoutSize(73,8, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_locals'] = QgsLayoutPoint(322, 278, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Source_rotate'] = 0
			self.template_parameters['Sous_titre_size'] = QgsLayoutSize(177,20, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_locals'] = QgsLayoutPoint(85, 28, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Sous_titre_rotate'] = 0
			self.template_parameters['Echelle_2_size'] = QgsLayoutSize(73,18, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_locals'] = QgsLayoutPoint(12, 260, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Echelle_2_rotate'] = 0
			self.template_parameters['Logo_2_size'] = QgsLayoutSize(40,40, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_locals'] = QgsLayoutPoint(12, 214, QgsUnitTypes.LayoutMillimeters)
			self.template_parameters['Logo_2_rotate'] = 0
	return self.template_parameters
