Patch level : 4.0
Files correlati : ve1.exe Ricompilazione Demo : [ ] Commento : Corretto calcolo rettangolo di stampa per campi di testo ad altezza variabile (campo descizione delle righe documento) git-svn-id: svn://10.65.10.50/trunk@15840 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
6920a41791
commit
e0307f3437
@ -1102,18 +1102,8 @@ bool TReport_field::dynamic_height() const
|
||||
|
||||
const TRectangle& TReport_field::get_draw_rect() const
|
||||
{
|
||||
TRectangle& rct = ((TReport_field*)this)->_draw_rct;
|
||||
if (dynamic_height())
|
||||
{
|
||||
TParagraph_string str(formatted_text(), rct.width()/100-1); // Sto un po' scarso
|
||||
int h = str.items() * 100;
|
||||
if (h <= 0)
|
||||
h = 100;
|
||||
if (h > _rct.height())
|
||||
h = _rct.height();
|
||||
rct.set_height(h);
|
||||
}
|
||||
return rct;
|
||||
// Dalla 4.0 il rettangolo e' sempre gia' calcolato correttamente!
|
||||
return _draw_rct;
|
||||
}
|
||||
|
||||
const TReport_font& TReport_field::font() const
|
||||
@ -1487,7 +1477,7 @@ void TReport_field::print(TBook& book) const
|
||||
|
||||
if (draw_hidden())
|
||||
{
|
||||
if (link().not_empty()) // Devo "stampare" i link anche se nascosti
|
||||
if (link().full()) // Devo "stampare" i link anche se nascosti
|
||||
{
|
||||
TRectangle rct = get_draw_rect();
|
||||
rct.set_height(0); rct.set_width(0);
|
||||
@ -1565,7 +1555,7 @@ void TReport_field::print(TBook& book) const
|
||||
{
|
||||
const TRectangle& pr = print_rect(book);
|
||||
book.draw_text(pr, str);
|
||||
if (link().not_empty())
|
||||
if (link().full())
|
||||
book.draw_link(pr, str, link());
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user