Check-in [9f1cc3aa4e]

Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Added -winsize option to 160
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 9f1cc3aa4e4b82c44ed42d7f8a7869c3ea0a9844ea825912e0a5dc4f0940628d
User & Date: dkf 2019-03-29 14:22:59.602
Context
2019-03-30
10:38
Refer to implementation branch in TIP 367 check-in: 2f5ed268bb user: dkf tags: trunk
2019-03-29
14:22
Added -winsize option to 160 check-in: 9f1cc3aa4e user: dkf tags: trunk
2019-03-28
02:55
Fix TIP number in display check-in: 4a36ce6061 user: kevin_walzer tags: trunk
Changes
Unified Diff Ignore Whitespace Patch
Changes to tip/160.md.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# TIP 160: Improvements to Terminal and Serial Channel Handling
	State:          Draft
	Type:           Project
	Tcl-Version:    8.7
	Vote:           Pending
	Post-History:	
	Author:         Donal K. Fellows <[email protected]>
	Created:        17-Oct-2003
	Tcl-Branch:     tip-160
-----

# Abstract

Terminals and other kinds of serial lines have other capabilities and
requirements that are not currently controllable using Tcl.  This TIP
adds new options to **fconfigure** to allow these advanced
capabilities to be supported within Tcl in a straight-forward way.

# Serial Line Discard Control

Serial lines are much slower devices than virtually anything else on a













|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# TIP 160: Improvements to Terminal and Serial Channel Handling
	State:          Draft
	Type:           Project
	Tcl-Version:    8.7
	Vote:           Pending
	Post-History:	
	Author:         Donal K. Fellows <[email protected]>
	Created:        17-Oct-2003
	Tcl-Branch:     tip-160
-----

# Abstract

Terminals, consoles and other kinds of serial lines have other capabilities and
requirements that are not currently controllable using Tcl.  This TIP
adds new options to **fconfigure** to allow these advanced
capabilities to be supported within Tcl in a straight-forward way.

# Serial Line Discard Control

Serial lines are much slower devices than virtually anything else on a
52
53
54
55
56
57
58
59
60

61
62
63
64
65
66
67

This option will be supported on all platforms where the underlying
serial API is sufficiently capable.  Where it is not supported, the
option will not be defined on serial channels.

# Echo and Cooking Control

Terminals have a number of modes of operation.  Two of the most useful
things that can be set relate to echoing and cooking.


_Echoing_ is fairly simple to understand.  If a terminal has echoing
turned on, every character read is written to the terminal
automatically without any action from the program reading from the
terminal.  Most of the time this is a good thing as people want to
see what they have typed, but sometimes it is not so good.  Examples
include where someone is typing in a password \(when they also want







|
|
>







52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68

This option will be supported on all platforms where the underlying
serial API is sufficiently capable.  Where it is not supported, the
option will not be defined on serial channels.

# Echo and Cooking Control

Terminals (on Unix) and consoles (on Windows) have a number of modes of
operation.  Two of the most useful things that can be set relate to echoing
and cooking.

_Echoing_ is fairly simple to understand.  If a terminal has echoing
turned on, every character read is written to the terminal
automatically without any action from the program reading from the
terminal.  Most of the time this is a good thing as people want to
see what they have typed, but sometimes it is not so good.  Examples
include where someone is typing in a password \(when they also want
110
111
112
113
114
115
116








117
118

119
120


121
122
123
124
125
system- and configuration-dependant, since users can use the `stty`
program to configure their terminals prior to calling Tcl.

If the user changes the **-inputmode**, the mode that was present when the
channel was opened will be restored when Tcl closes the channel, just as if
the **reset** option is used.









# Platform Portability


This TIP does not guarantee support for any of these options on non-POSIX
platforms (specifically including Windows), but it does authorize the support


as documented on any platform where it is practical to do so.

# Copyright

This document has been placed in the public domain.







>
>
>
>
>
>
>
>


>
|
|
>
>
|




111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
system- and configuration-dependant, since users can use the `stty`
program to configure their terminals prior to calling Tcl.

If the user changes the **-inputmode**, the mode that was present when the
channel was opened will be restored when Tcl closes the channel, just as if
the **reset** option is used.

# Terminal Size

It is common for terminals to be able to be of variable size. To accommodate
this, terminals (on Unix) and consoles (on Windows) will gain a read-only
**fconfigure** option, **-winsize**, that when read will return a two element
list with the current width (first element) and height (second element) of the
terminal/console.

# Platform Portability

On Unix, terminals cover both serial lines and consoles, and so gain all
options.

On Windows, serial lines and consoles are separate channel types, so
**-closemode** is only supported on serial lines, and **-inputmode** and
**-winsize** are only supported on consoles.

# Copyright

This document has been placed in the public domain.