lxRegMasterDiffName
lxRegMasterDiffName(
S_function
)
=> t / nil
Description
Registers a SKILL function that can return a name for the master difference reported by the Check Against Source command.
Argument
|
Name of the SKILL function to be registered. The SKILL function must take the following two arguments and return a string. |
Value Returned
Example
lxRegMasterDiffName('testMasterDiffName)
Where the SKILL function testMasterDiffName is defined as:
procedure(testMasterDiffName1(master expected)
let((_mbbox _cv _tok _lib _cell _view _views (_name "")
cH nH cW nW _nbbox)
_tok = parseString(expected "/")
_lib = car(_tok)
_cell = cadr(_tok)
_views = caddr(_tok)
_view = substring(_views 2 (strlen(_views) - 2))
_tok = parseString(_view " ")
_view = car(_tok)
_cv = dbOpenCellView(_lib _cell _view)
when(_cv
_mbbox = master~>bBox
cH = testBoxDimY(_mbbox)
cW = testBoxDimX(_mbbox)
_nbbox = _cv~>bBox
nH = testBoxDimY(_nbbox)
nW = testBoxDimX(_nbbox)
cond(
(nH > cH && nW > cW
_name = "Taller and wider"
)
(nH < cH && nW < cW
_name = "Shorter and thiner"
)
(testEqualBasic(nH cH) && nW > cW
_name = "Wider"
)
(testEqualBasic(nH cH) && nW < cW
_name = "Thinner"
)
(nH > cH && testEqualBasic(cW nW)
_name = "Taller"
)
(nH < cH && testEqualBasic(cW nW)
_name = "Shorter"
)
)
dbClose(_cv)
)
_name
)
)
Return to top