function c_cell($d = null) { $o = array(); $a = optimize_args(func_get_args()); if (count($a) && ($c = isset($a[0]) ? $a[0] : false)) { if (isNum($c)) { unset($a[0]); for ($i = 0; $i < $c; $i++) { $o[] = $this->c_cell($a); } } else { foreach ($a as $v) { if (isDrw($v)) { $o[] = $this->c_cell($v); } } } return count($o) == 1 ? $o[0] : $o; } else { return cEle($this->child_type)->do_method(array('class' => 'frame_cell'), $a)->O; } }
function trim($t = '') { $a = optimize_args(func_get_args()); if (isNum($a[0])) { $b = shift($a); } else { $b = 0; } trim($this->O); for ($i = 0; $i < count($a); $i++) { foreach ($a as $v) { if (isStr($v)) { if ($v == 'number') { $c = '\\d'; } else { $c = $v; } $lef = '^(\\/?(\\s+|)(' . $c . '+))'; $rig = '(' . $c . '+)?(\\s+|)$'; $this->O = preg_replace('/' . (!isDrw($b) ? $lef . '|' . $rig : ($b[1] < 0 ? $lef : $rig)) . '/', '', $this->O); } } } return $this; }