Пример #1
0
static Line*
isdefinition(Line *t, int *clip, int *kind)
{
    Line *ret;

    *kind = 1;
    if ( (ret = is_discount_dt(t,clip)) )
	return ret;

    *kind=2;
    return is_extra_dt(t,clip);
}
Пример #2
0
static Line*
is_discount_dt(Line *t, int *clip)
{
#if USE_DISCOUNT_DL
    if ( t && t->next
	   && (S(t->text) > 2)
	   && (t->dle == 0)
	   && (T(t->text)[0] == '=')
	   && (T(t->text)[S(t->text)-1] == '=') ) {
	if ( t->next->dle >= 4 ) {
	    *clip = 4;
	    return t;
	}
	else
	    return is_discount_dt(t->next, clip);
    }
#endif
    return 0;
}
Пример #3
0
static Line*
is_discount_dt(Line *t, int *clip, DWORD flags)
{
    if ( !(flags & MKD_NODLDISCOUNT)
	   && t
	   && t->next
	   && (S(t->text) > 2)
	   && (t->dle == 0)
	   && (T(t->text)[0] == '=')
	   && (T(t->text)[S(t->text)-1] == '=') ) {
	if ( t->next->dle >= 4 ) {
	    *clip = 4;
	    return t;
	}
	else
	    return is_discount_dt(t->next, clip, flags);
    }
    return 0;
}