Juergen Spitzmueller wrote:
> John Levon wrote:
> 
>>There is a problem with "Layout/Document/Paper" settings:
>>If I leave the headheight, headsep, footskip empty, I would assume they
>>are
>>zero.  But they are by default NOT!  I do not know the default values.
> 
> [snip]
> 
> This is a bug. It applies also to the custom margins. If the fields are empty, 
> then the default margins from geometry are used, which are not "0", but "0" 
> will be read in as empty field. So it's a rather grave bug.
> 
> AFAICS, the bug is in xforms_helpers.C (void updateWidgetsFromLength), line 
> 155 (len.zero()):

I was actually struggling with the same problem while modifying the graphics dialog.

LyXLength could be augmented with a private member "bool empty", that is only TRUE
in case of an empty-string input field.

In stead of testing "if (len.zero())", we should then test "if (len.empty())".
The len.zero() is obsolete and the value zero should be treated just as any
other value.

Cheers,
Rob.

Reply via email to