octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #50041] Setting non-valid values for graphics


From: Markus Mützel
Subject: [Octave-bug-tracker] [bug #50041] Setting non-valid values for graphics properties should throw an error
Date: Thu, 19 Jan 2017 00:17:38 +0000 (UTC)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:51.0) Gecko/20100101 Firefox/51.0

Follow-up Comment #4, bug #50041 (project octave):

Thank you, Pantxo, for reviewing.

I was trying to add the new constraints to all properties that would need
them. But checking all double, row_vector and array properties in Matlab for
NaN, Inf and negative values is quite tedious.

Additionally, some properties have quite unique constraints. E.g. the
"*position" properties of figure are allowed to have negative values in the
first two elements (x and y position). But the last two elements (width and
height) must be positive. The generic constraints that we have cannot perform
this kind of check. Checking this in the update_NAME function is too late
because the values are already set and the old values are overwritten. Even if
we still can throw an error there, we cannot restore the previous (working)
state. Maybe there should be an optional check_NAME function that could be
called before the value is set?
But this can probably wait for a later patch.

Anyway, I will clean up what I have so far and post the updated patch as soon
as it is ready and tested.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?50041>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]