Spec-Zone .ru
спецификации, руководства, описания, API
Spec-Zone .ru
спецификации, руководства, описания, API
Библиотека разработчика Mac Разработчик
Поиск

 

Эта страница руководства для  версии 10.9 Mac OS X

Если Вы выполняете различную версию  Mac OS X, просматриваете документацию локально:

Читать страницы руководства

Страницы руководства предназначаются как справочник для людей, уже понимающих технологию.

  • Чтобы изучить, как руководство организовано или узнать о синтаксисе команды, прочитайте страницу руководства для страниц справочника (5).

  • Для получения дополнительной информации об этой технологии, ищите другую документацию в Библиотеке Разработчика Apple.

  • Для получения общей информации о записи сценариев оболочки, считайте Shell, Пишущий сценарий Учебника для начинающих.



tk(n)                                       Tk Built-In Commands                                       tk(n)



____________________________________________________________________________________________________________

NAME
       tk - Manipulate Tk internal state

SYNOPSIS
       tk option ?arg arg ...?
____________________________________________________________________________________________________________


DESCRIPTION
       The  tk command provides access to miscellaneous elements of Tk's internal state.  Most of the infor-mation information
       mation manipulated by this command pertains to the application as a whole, or to a screen or display,
       rather  than to a particular window.  The command can take any of a number of different forms depend-ing depending
       ing on the option argument.  The legal forms are:

       tk appname ?newName?
              If newName is not specified, this command returns the name of the application (the  name  that
              may  be  used in send commands to communicate with the application).  If newName is specified,
              then the name of the application is changed to newName.  If the given name is already in  use,
              then  a  suffix  of the form " #2" or " #3" is appended in order to make the name unique.  The
              command's result is the name actually chosen.  newName should not start with a capital letter.
              This  will interfere with option processing, since names starting with capitals are assumed to
              be classes;  as a result, Tk may not be able to find some options  for  the  application.   If
              sends  have  been  disabled  by deleting the send command, this command will reenable them and
              recreate the send command.

       tk caret window ?-x x? ?-y y? ?-height height?
              Sets and queries the caret location for the display of the specified Tk  window  window.   The
              caret is the per-display cursor location used for indicating global focus (e.g. to comply with
              Microsoft Accessibility guidelines), as well as for location of the over-the-spot XIM (X Input
              Methods)  or  Windows IME windows.  If no options are specified, the last values used for set-ting setting
              ting the caret are return in option-value pair format.  -x and  -y  represent  window-relative
              coordinates,  and  -height  is the height of the current cursor location, or the height of the
              specified window if none is given.

       tk scaling ?-displayof window? ?number?
              Sets and queries the current scaling factor used by Tk to convert between physical units  (for
              example,  points, inches, or millimeters) and pixels.  The number argument is a floating point
              number that specifies the number of pixels per point on window's display.  If the window argu-ment argument
              ment  is omitted, it defaults to the main window.  If the number argument is omitted, the cur-rent current
              rent value of the scaling factor is returned.

              A "point" is a unit of measurement equal to 1/72 inch.  A scaling factor of 1.0 corresponds to
              1 pixel per point, which is equivalent to a standard 72 dpi monitor.  A scaling factor of 1.25
              would mean 1.25 pixels per point, which is the setting for a 90 dpi monitor; setting the scal-ing scaling
              ing  factor  to  1.25 on a 72 dpi monitor would cause everything in the application to be dis-played displayed
              played 1.25 times as large as normal.  The initial value for the scaling factor  is  set  when
              the application starts, based on properties of the installed monitor, but it can be changed at
              any time.  Measurements made after the scaling factor is changed will use the new scaling fac-tor, factor,
              tor, but it is undefined whether existing widgets will resize themselves dynamically to accom-modate accommodate
              modate the new scaling factor.

       tk inactive ?-displayof window? ?reset?
              Returns a positive integer, the number of milliseconds since the last time the user interacted
              with the system. If the -displayof option is given then the return value refers to the display
              of window; otherwise it refers to the display of the application's main window.

              tk inactive will return -1, if querying the user inactive time is not supported by the system,
              and in safe interpreters.

              If  the  literal  string  reset  is given as an additional argument, the timer is reset and an
              empty string is returned. Resetting the inactivity time is forbidden in safe interpreters  and
              will throw and error if tried.

       tk useinputmethods ?-displayof window? ?boolean?
              Sets  and  queries  the  state  of  whether  Tk should use XIM (X Input Methods) for filtering
              events.  The resulting state is returned.  XIM  is  used  in  some  locales  (i.e.,  Japanese,
              Korean),  to handle special input devices. This feature is only significant on X.  If XIM sup-port support
              port is not available, this will always return 0.  If  the  window  argument  is  omitted,  it
              defaults  to  the  main  window.   If  the  boolean  argument is omitted, the current state is
              returned.  This is turned on by default for the main display.

       tk windowingsystem
              Returns the current Tk windowing system, one of x11 (X11-based), win32 (MS Windows),  or  aqua
              (Mac OS X Aqua).

SEE ALSO
       send(n), winfo(n)

KEYWORDS
       application name, send



Tk                                                   8.4                                               tk(n)

Сообщение о проблемах

Способ сообщить о проблеме с этой страницей руководства зависит от типа проблемы:

Ошибки содержания
Ошибки отчета в содержании этой документации к проекту Tk.
Отчеты об ошибках
Сообщите об ошибках в функциональности описанного инструмента или API к Apple через Генератор отчетов Ошибки и к проекту Tk через их страницу создания отчетов ошибки.
Форматирование проблем
Отчет, форматирующий ошибки в интерактивной версии этих страниц со ссылками на отзыв ниже.