<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif; "><div><div><div>I have a project that I have built in Qt (C++) that I am porting to QtRuby.  I am using the same mainwindow.ui form for both projects.</div><div><br></div><div>In the QtRuby project, I cannot change the font size in the QTextBrowser.</div><div><br></div><div>The following method makes no change in the QTextBrowser.  I know it is being called correctly because of the puts statements.</div><div><br></div><div><div> def setFontSize(size)</div><div><span class="Apple-tab-span" style="white-space: pre; ">     </span>puts size.to_f  # outputs the correct value</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>@ui.textNote.setFontPointSize(size.to_f)</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>puts @ui.textNote.currentFont.pointSizeF  # outputs 11.0 regardless of size</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre">    </span>font = @ui.textNote.currentFont</div><div><span class="Apple-tab-span" style="white-space:pre">      </span>puts font.pointSizeF # outputs 11.0 always</div><div><span class="Apple-tab-span" style="white-space:pre">   </span>font.pointSizeF = 32.4</div><div><span class="Apple-tab-span" style="white-space:pre">       </span>puts font.pointSizeF # outputs 32.4</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>@ui.textNote.currentFont = font</div><div><span class="Apple-tab-span" style="white-space:pre">      </span>p @ui.textNote.currentFont.pointSizeF # outputs 11.0 always</div><div>  end</div></div><div><br></div><div>The following method also doesn't work as expected.  It opens a Font Dialog and sets the font family correctly as well as bold, underline and italic, but the font size never changes.</div><div><br></div><div><div>  def showFonts</div><div>    ok = Qt::Boolean.new</div><div>    font = Qt::FontDialog.getFont(ok, @ui.textNote.currentFont, self);</div><div><span class="Apple-tab-span" style="white-space:pre">   </span>if(ok)</div><div>      @ui.textNote.setCurrentFont(font);</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>end</div><div>  end</div></div><div><br></div><div>Any ideas?</div><div><br></div><div><div><font class="Apple-style-span" color="rgb(0, 0, 0)"><font class="Apple-style-span" face="Calibri">- GrumpyMayor</font></font></div></div></div></div></body></html>