title: How to create a button in QT with multiple properties?
body: <p>I want to create a button with the following properties</p>
  
  <ol>
  <li>translucent</li>
  <li>WordWrap</li>
  <li>Relative font size</li>
  <li>When you click on the button, the text color and the background color of the button changes</li>
  </ol>
  
  <p>I can achieve those separately with</p>
  
  <p><strong>translucent and a changing colors</strong></p>
  
  <pre><code>button-&gt;setFlat(true);
  button-&gt;setStyleSheet(
              "QPushButton {"
              "color: blue;"
              "background-color: rgba(255, 255, 255, 90)"
              "}"
              "QPushButton:pressed {"
              "color: lime;"
              "background-color: rgba(255, 255, 255, 50)"
              "}"
              "QPushButton:flat {"
              "border: none; "
              "}"
              );
  </code></pre>
  
  <p><strong>word wrapping:</strong>   </p>
  
  <pre><code>   QPushButton button;
      QHBoxLayout layout;
      button.setLayout(&amp;layout);
      QLabel label("LOOOOOOOOOOOOOOOOOONGGGGGGGGGGG TEXXXXXXXXXT");
      label.setWordWrap(true);
      layout.addWidget(&amp;label);
      button.show();
  </code></pre>
  
  <p><strong>Relative font size:</strong> </p>
  
  <pre><code>void MyButton::resizeEvent(QResizeEvent *event)
  {
      int pixelsHeight = this-&gt;size().height()/2;
      if(pixelsHeight &gt; 24) pixelsHeight = 24;
      if(pixelsHeight &lt; 8) pixelsHeight = 8;
  
      m_font.setPixelSize(pixelsHeight);
      label-&gt;setFont(m_font);
  }
  </code></pre>
  
  <p>How can I achieve all at the same time?</p>