Guest User

Untitled

a guest
Nov 9th, 2018
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.87 KB | None | 0 0
  1. labelAdditionalText = new QLabel("This will reset all the counters (including the start date)");
  2. labelAdditionalText->setObjectName(QStringLiteral("labelAdditionalText"));
  3.  
  4. labelUsername = new QLabel("Username :");
  5. labelUsername->setObjectName(QStringLiteral("labelUsername"));
  6.  
  7. lineEditUsername = LayoutUtils::createTouchLineEdit(WIDGET_KEYBOARD, EDITMODE_STANDARD);
  8. lineEditUsername->setObjectName(QStringLiteral("lineEditUsername"));
  9. lineEditUsername->setMaxLength(50);
  10.  
  11. labelPassword = new QLabel("Password :");
  12. labelPassword->setObjectName(QStringLiteral("labelPassword"));
  13.  
  14. lineEditPassword = LayoutUtils::createTouchLineEdit(WIDGET_KEYBOARD, EDITMODE_STANDARD);
  15. lineEditPassword->setObjectName(QStringLiteral("lineEditPassword"));
  16. lineEditPassword->setMaxLength(50);
  17. lineEditPassword->setEchoMode(TouchLineEdit::Password);
  18.  
  19. pushButtonOk = new QPushButton("OK");
  20. pushButtonOk->setObjectName(QStringLiteral("pushButtonOk"));
  21. pushButtonOk->setAutoDefault(false);
  22.  
  23. pushButtonCancel = new QPushButton("Cancel");
  24. pushButtonCancel->setObjectName(QStringLiteral("pushButtonCancel"));
  25. pushButtonCancel->setAutoDefault(false);
  26.  
  27. QGridLayout* pxAdditionTextLayout = new QGridLayout();
  28. pxAdditionTextLayout->addWidget(labelAdditionalText);
  29. //pxAdditionTextLayout->
  30.  
  31. QGridLayout * pxLineEditLayout = new QGridLayout();
  32. pxLineEditLayout->addWidget(labelUsername, 0, 0);
  33. pxLineEditLayout->addWidget(lineEditUsername, 0, 1);
  34. pxLineEditLayout->addWidget(labelPassword, 1, 0);
  35. pxLineEditLayout->addWidget(lineEditPassword, 1, 1);
  36.  
  37. QGridLayout * pxButtonLayout = new QGridLayout();
  38. pxButtonLayout->addWidget(pushButtonOk, 0, 0);
  39. pxButtonLayout->addWidget(pushButtonCancel, 0, 1);
  40.  
  41. QGridLayout * pxGridLayout = new QGridLayout();
  42. pxGridLayout->addLayout(pxAdditionTextLayout, 0, 0);
  43. pxGridLayout->addLayout(pxLineEditLayout, 1, 0);
  44. pxGridLayout->addLayout(pxButtonLayout, 2, 0, Qt::AlignRight);
  45.  
  46. setLayout(pxGridLayout);
Add Comment
Please, Sign In to add comment