⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 lo

📁 Algorithms for Image Processing and Computer Vision Source Code
💻
字号:
@c ----------------------------------------------------------------------
@node localeconv, locale
@heading @code{localeconv}
@subheading Syntax

@example
#include <locale.h>

struct lconv *localeconv(void);
@end example

@subheading Description

This function returns a pointer to a static structure that contains
information about the current locale.  The structure contains these
fields:

@table @code

@item char *currency_symbol

A string that should be used when printing local currency.

@item char *decimal_point

A string that is used to separate the integer and fractional portions
of real numbers in @code{printf}.  Currently, only the first character
is significant.

@item char *grouping

An array of numbers indicating the size of groupings for non-monetary
values to the left of the decimal point.  The first number is the size
of the grouping just before the decimal point.  A number of zero means
to repeat the previous number indefinitely.  A number of @code{CHAR_MAX}
means to group the remainder of the digits together.

@item char *int_curr_symbol

A string that should be used when formatting monetary values for local
currency when the result will be used internationally.

@item char *mon_decimal_point

A string that separates the interger and fractional parts of monetary
values.

@item char *mon_grouping

Same as grouping, but for monetary values.

@item char *negative_sign

A string that is used to represent negative monetary values.

@item char *positive_sign

A string that is used to represent positive monetary values.

@item char *thousands_sep

The grouping separator for non-monetary values.

@item char frac_digits

The number of digits to the right of the decinal point for monetary
values.

@item char int_frac_digits

Like frac_digits, but when formatting for international use.

@item char n_cs_precedes

If nonzero, the currency string should precede the monetary value if
the monetary value is negative.

@item char n_sep_by_space

If nonzero, the currency string and the monetary value should be
separated by a space if the monetary value is negative.

@item char n_sign_posn

Determines the placement of the negative indication string if the
monetary value is negative.

@table @asis
@item 0
($value), (value$)
@item 1
-$value, -value$
@item 2
$value-, value$-
@item 3
-$value, value-$
@item 4
$-value, value$-
@end table

@item char p_cs_precedes
@item char p_sep_by_space
@item char p_sign_posn

These are the same as n_*, but for when the monetary value is
positive.

@end table

Note that any numeric field may have a value of @code{CHAR_MAX}, which
indicates that no information is available.

@subheading Return Value

A pointer to the @code{struct lconv} structure.

@subheading Example

@example
struct lconv *l = localeconv;
printf("%s%d\n", l->negative_sign, value);
@end example

@c ----------------------------------------------------------------------
@node localtime, time
@heading @code{localtime}
@subheading Syntax

@example
#include <time.h>

struct tm *localtime(const time_t *tod);
@end example

@subheading Description

Converts the time represented by @var{tod} into a structure, correcting
for the local timezone.  @xref{gmtime}

@subheading Return Value

A pointer to a static structure which is overridden with each call. 

@c ----------------------------------------------------------------------
@node lock, io
@heading @code{lock}
@subheading Syntax

@example
#include <io.h>

int lock(int fd, long offset, long length);
@end example

@subheading Description
Locks a region in file @var{fd} using MS-DOS file sharing interface.
The region of @var{length} bytes, starting from @var{offset}, will
become entirely inaccessible to other processes. If multiple locks
are used on a single file they must be non-overlapping. The lock
must be removed before the file is closed.

This function will fail unless SHARE, or a network software
providing similar interface, is installed. This function is
compatible with Borland C++ function of the same name.

@xref{unlock}.

@subheading Return Value
Zero if successful, nonzero if not.

@c ----------------------------------------------------------------------
@node longjmp, misc
@heading @code{longjmp}
@subheading Syntax

@example
#include <setjmp.h>

void longjmp(jmp_buf env, int val);
@end example

@subheading Description

This function reverts back to a CPU state that was stored in @var{env}
by @code{setjmp} (@pxref{setjmp}).  The state includes all CPU registers,
so any variable in a register when @code{setjmp} was called will be
preserved, and all else will be indeterminate.

The value passed as @var{val} will be the return value of @code{setjmp}
when it resumes processing there.  If @var{val} is zero, the return
value will be one. 

@subheading Return Value

This function does not return.

@subheading Example

@example
jmp_buf j;
if (setjmp(j))
  return;
do_something();
longjmp(j);
@end example

@c ----------------------------------------------------------------------
@node longjmperror, misc
@heading @code{longjmperror}
@subheading Syntax

@example
void longjmperr(void);
@end example

@subheading Description

This function is internal and is used by setjmp and longjmp when they
detect an invalid longjmp request.

@subheading Return Value

None.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -