Bordure d'un tableau dans QTextEdit
Bonjour,
Voici mon problème, j'ai un tableau dans un QTextEdit créé avec insertTable.
Je change les bordures avec :
Code:
1 2 3 4 5 6 7 8
| QTextCursor curseur = ui->txt_page_1->textCursor(); // Récupération du QTextCursor de la zone de texte
if(curseur.currentTable()){
QTextTable *table = curseur.currentTable();
QTextTableFormat format = table->format();
format.setBorderStyle(QTextFrameFormat::BorderStyle_Dotted);
table->setFormat(format);
} |
Le problème c'est que seul le contour du tableau c'est mis en forme.
Voici la source créé :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
p, li { white-space: pre-wrap; }
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;">
<table border="1" style=" border-style:dotted; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px;" cellspacing="2" cellpadding="0">
<tr>
<td></td>
<td></td>
<td></td></tr>
<tr>
<td></td>
<td></td>
<td></td></tr>
<tr>
<td></td>
<td></td>
<td></td></tr></table></body></html> |
Avez vous une idée de la façon permettant de mettre la forme sur les lignes également ?
Merci par avance à tous