Advertisement
Guest User

einstellungen.qml

a guest
Nov 13th, 2022
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
QML 5.19 KB | Money | 0 0
  1. /*
  2.  * Copyright (C) 2022  Dirk Unverzagt
  3.  * Dieses Programm ist kostenlose Software: Sie können es weitergeben und/oder modifizieren
  4.   * Es unterliegt den Bedingungen der GNU General Public License, wie veröffentlicht von
  5.   * die Free Software Foundation; Fassung 3.
  6.   *
  7.   * mwst wird in der Hoffnung verteilt, dass es nützlich sein wird,
  8.   * jedoch OHNE JEGLICHE GEWÄHRLEISTUNG; sogar ohne die stillschweigende Garantie von
  9.   * MARKTFÄHIGKEIT oder EIGNUNG FÜR EINEN BESTIMMTEN ZWECK. Siehe die
  10.   * GNU General Public License für weitere Details.
  11.   *
  12.   * Sie sollten eine Kopie der GNU General Public License erhalten haben
  13.   * zusammen mit diesem Programm. Falls nicht, siehe <http://www.gnu.org/licenses/>.
  14.  *
  15.  * This program is free software: you can redistribute it and/or modify
  16.  * it under the terms of the GNU General Public License as published by
  17.  * the Free Software Foundation; version 3.
  18.  *
  19.  * mwst is distributed in the hope that it will be useful,
  20.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  21.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  22.  * GNU General Public License for more details.
  23.  *
  24.  * You should have received a copy of the GNU General Public License
  25.  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  26.  */
  27.  
  28.  
  29. import QtQuick 2.7
  30. import Ubuntu.Components 1.3
  31. import QtQuick.Controls 2.2
  32. import QtQuick.Layouts 1.3
  33. import Qt.labs.settings 1.0
  34. import QtQuick.LocalStorage 2.0
  35.  
  36.  
  37.  
  38.  
  39.  
  40. MainView {
  41.     id: root
  42.     objectName: 'mainView'
  43.     applicationName: 'mwst.dl8aax'
  44.     automaticOrientation: true
  45.  
  46.     width: units.gu(45)
  47.     height: units.gu(70)
  48.  
  49.     Item {
  50.          Component.onCompleted: {    
  51.                                
  52.                                  
  53.                                 }
  54.         }
  55.     Settings {
  56.                 id:settings1
  57.                 property alias mwstt: areatext.text
  58.  
  59.                 }
  60.     function speichern() {
  61.                          
  62.                           root2.machmacombob(areatext.text)
  63.                          
  64.  
  65.                          }
  66.     Page {
  67.           anchors.fill: parent
  68.  
  69.           Rectangle {
  70.                     id: rectangle_1
  71.                     x: units.gu(2)
  72.                     y: units.gu(2)
  73.                     width: units.gu(45)-units.gu(5)
  74.                     height: units.gu(65)
  75.                     color: "#ddd9d9"
  76.                     radius: 4
  77.                     border.color: "#be0cc4"
  78.                     border.width: units.gu(0.2)
  79.  
  80.                     Text {
  81.                           id: utext
  82.                           anchors.top  : rectangle_1.top
  83.                           anchors.horizontalCenter: rectangle_1.horizontalCenter
  84.                           anchors.topMargin: units.gu(3)
  85.                           y: rectangle_1.y
  86.                           text: i18n.tr('Einstellungen')
  87.                           font.pixelSize:  units.gu(2.5)
  88.                           color: "darkorange"
  89.                           }
  90.  
  91.  
  92.                     Text {
  93.                           id: itext
  94.                           anchors.top  : utext.bottom
  95.                           //anchors.centerIn: parent
  96.                           anchors.topMargin: units.gu(3)
  97.                           anchors.horizontalCenter: rectangle_1.horizontalCenter
  98.                           y: rectangle_1.y
  99.                           text: i18n.tr('MWST Sätze\nSteuersatz und Kommentar durch Komma getrennt')
  100.                           font.pixelSize:  units.gu(1.5)
  101.                           //color: "blue"
  102.                           }
  103.                                 ScrollView {
  104.                                             id : scolli
  105.                                             anchors.top  : itext.bottom
  106.                                             anchors.bottom : but.top
  107.                                             height: units.gu(22)
  108.                                             width: units.gu(40)
  109.                                             TextArea {
  110.                                                       id : areatext
  111.                                                       width: rectangle_1.width
  112.                                                       //anchors.centerIn: scrollrect
  113.                                                       text: " 7%, Lebensmittel\n19 %, Normaler Steuersatz"
  114.                                                       font.pixelSize:  units.gu(2)
  115.                                                       }
  116.                                           }// Ende ScrollView
  117.  
  118.                     }// Ende
  119.                     Button {
  120.                                   id : but
  121.                                   //anchors.horizontalCenter: rectangle2.center
  122.                                   anchors.top  : scolli.bottom
  123.                                   anchors.topMargin: units.gu(3)
  124.                                   anchors.centerIn: parent
  125.  
  126.                                 //  x : rectangle2.center - but / 2
  127.                                   text: i18n.tr("Speichern")
  128.                                   onClicked: { speichern () }
  129.                                   }
  130.          }// Ende page
  131.  
  132.          }// Ende MainView
  133.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement