ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • Why Does Pressing Tab Generate Key Event
    카테고리 없음 2020. 8. 28. 22:14



    So if the user presses a character key, but the default is prevented onkeydown or onkeypress, the textinput event does not. Fire since the sequence does not result in a character being added. The keydown/keypress scheme outlined above is originally a Microsoft invention that Safari 3.1 copied for reasons explained by Alexey Proskuryakov of the.

    Jun 29, 2009  Simulate tab key by pressing enter key If this is your first visit, you may have to register before you can post. To start viewing messages, select the. Mar 26, 2017 We know that, generally, pressing the Tab key moves the input focus to next control and Shift-Tab to previous in the tab order of the form. When working with Windows applications, some users intuitively expect the Enter key to behave like a Tab key.

    Tab key on a standard keyboard (on upper left)

    The tab key

    Tab ↹

    (abbreviation of tabulator key[1] or tabular key[2]) on a keyboard is used to advance the cursor to the next tab stop.

    History[edit]

    The tab rack from a Flexowriter model 2201. On this machine, the tab-rack is removable for easy reconfiguration.

    The word tab derives from the word tabulate, which means 'to arrange data in a tabular, or table, form.' When a person wanted to type a table (of numbers or text) on a typewriter, there was a lot of time-consuming and repetitive use of the space bar and backspace key. To simplify this, a horizontal bar was placed in the mechanism called the tabulator rack. Pressing the tab key would advance the carriage to the next tabulator stop. The original tabulator stops were adjustable clips that could be arranged by the user on the tabulator rack. Fredric Hillard filed a patent application for such a mechanism in 1900.[3]

    The tab mechanism came into its own as a rapid and consistent way of uniformly indenting the first line of each paragraph. Often a first tab stop at 5 or 6 characters was used for this, far larger than the indentation used when typesetting. For numeric data, however, the logical place for the tab stop is the location of the least significant digit. Tabbing to this location and then pressing the backspace key to back up to the position of the first digit is practical but slow. Various schemes for numeric tabs were proposed. For example, in 1903, Harry Dukes and William Clayton filed for a patent on a tab mechanism with multiple tab keys numbered 1, 10, 100, etc. Pressing 1 was a simple tab. Pressing 10 advanced to the space before the tab, pressing 100 advanced to the position 2 spaces before the tab.[4]

    Initially tab stops were set by adding and removing clips from the tab rack, but Edward Hess working for the Royal Typewriter Company filed for a patent in 1904 covering a system where the tab stops were permanently mounted on the tab bar. To set or reset a tab for a particular column, the tab stop for that column was simply rotated in or out of engagement.[5] In 1940, James Koca filed for a patent on a mechanism allowing the tab stops for each column to be set and cleared from the keyboard, eliminating the need for the typist to bend over the back of the machine to directly manipulate the tab rack.[6] These keys, if present, are typically labeled tab set and tab clear.

    Modern usage[edit]

    In word processing and text editing, the Tab key will move the insertion point to the next tab stop in a table, insert the ASCII tab character, or insert many space characters (depending on the program used).

    When filling out a computerized form, pressing Tab will sometimes move the cursor to the next field (and Shift-Tab will move the cursor to the previous field), eliminating the need to use a mouse to click in an adjacent field.

    In many graphical applications, especially on Windows, the Tab key will move the focus to everycontrol or widget such as buttons so that the user interface can be used without a mouse at all (this was part of the IBM Common User Access design). On macOS, this is an option called 'Full Keyboard Access'.

    A feature called tab completion can be used to complete a partially typed piece of text. For example, in some command-line interfaces, you may type the first few characters of a command or file-name, then press Tab. If there is no ambiguity about your intent, the rest of the characters will appear automatically. This usage is more common on Linux, Unix, and Unix-like systems than Windows.

    In 'PC' video games, the Tab key is very often used to show scores in multiplayer games. For single player games it is also used to show the world map or the player's inventory (or any other useful info).

    In software engineering, when developing computer programs or storing and manipulating data in files, the Tab character is often used for indentation purposes to help guide the flow of reading and add semantic structure to the code or data. Some programmers and programming languages prefer the usage of multiple whitespace characters instead for that purpose.

    Tab characters[edit]

    The most known and common tab is a horizontal tab (HT), which in ASCII has the decimal character code of 9, and may be referred to as

    Ctrl

    +

    I

    or ^I. In C and many other programming languages the escape code t can be used to put this character into a string constant. The horizontal tab is usually generated by the Tab key on a standard keyboard.

    A vertical tab (VT) also exists and has ASCII decimal character code 11 (

    Ctrl

    +

    K

    or ^K), escape character v.

    In EBCDIC the code for HT is 5. VT is 11 (coincidentally the same as in ASCII).

    Originally, printer mechanisms used mechanical tab stops to indicate where the tabs went. This was done horizontally with movable metal prongs in a row, and vertically with a loop of mylar or other tape the length of a page with holes punched in it to indicate the tab stops. These were manually set to match the pre-printed forms that were loaded into the printer. In practice, settable tab stops were rather quickly replaced with fixed tab stops, de facto standardized at every multiple of 8 characters horizontally, and every 6 lines vertically. A printing program could send zero or more tabs to get to the closest tab stop above and left of where it wanted to print, then send line feeds and spaces to get to the final location. Tab characters simply became a form of data compression.

    Despite five characters being the typical paragraph indentation on typewriters at that time, the horizontal tab size of 8 evolved because as a power of two it was easier to calculate with the limited digital electronics available. Using this size tab to indent code results in lots of white space on the left, so most text editors for code, such as IDEs, allow the size of the tab to be changed, and some (in particular on Windows) default to 4 instead of 8. Disagreements between programmers about what size tabs are correct (and whether to use tabs at all) are common[citation needed]. Modern editors usually have Tab key insert the indentation the programmer wants as spaces or combinations of tabs and spaces.

    Why Does Pressing Tab Generate Key Event Free

    ISO 6429 includes the codes 136 (Horizontal Tabulation Set), 137 (Horizontal Tabulation with Justification) and 138 (Vertical Tabulation Set) that were intended to allow the program to set and clear tab stops. This is rarely used or supported.

    Tab-separated values[edit]

    Tab-separated values (TSV) are a common de facto standard[citation needed][dubious] for exporting and importing database or spreadsheet field values. Text divided into fields delimited by tabs can often be pasted into a word processor and formatted into a table with a single command. For example, in Microsoft Word 2010, Insert > Table > Convert Text to Table... is the necessary command, producing a dialog where the user selects further details.

    The TSV convention for exporting data may be compared to the alternative comma-separated values (CSV) convention.

    Gopher menus use tab-separated values to indicate selectors.

    TSV has also been cited in a modern approach to solving the programming debate regarding the use of tabs and spaces for code alignment called elastic tabstops.[7] This idea uses a scheme called tab-separated columns (TSC) rather than the similar tab-separated values (TSV).

    HTML[edit]

    In HTML the horizontal tab is coded using &#9; or &tab;[8][9] but as with all whitespace characters in HTML, this will be displayed as a single space except inside <pre> tags (or other elements with CSS attribute white-space set to pre).

    Here is an example:

    HTML
    Inside <pre>
    Outside <pre>

    This line begins with a single tab.Herearesomemoretabcharacters!T.......T.......T.......T.......T.......T.......T.......T

    Notice that the tab at the start of a line is removed outside <pre>, the 8-character spacing, and how a tab stop is skipped if there are more than 8 characters since last one.

    CSS 3 defines tab-size property, which adjusts the number of spaces for the tab character from the default of 8.[10] The latest version of WebKit supports the tab-size property. The Opera web browser supports the -o-tab-size CSS property, the Firefox web browser supports the -moz-tab-size CSS property with the same meaning.[11]

    The vertical tab is &#xB; but is not allowed in SGML[citation needed]; this includes XML 1.0[12] and HTML.

    Unicode[edit]

    The Unicode code points for the (horizontal) tab character, and the more rarely used vertical tab character are copied from ASCII:[13]

    • U+0009<control-0009> (CHARACTER TABULATION, horizontal tabulation (HT), tab)
    • U+000B<control-000B> (LINE TABULATION, vertical tabulation (VT))

    Why Does Pressing Tab Generate Key Event

    The tab characters can be graphically represented by special symbols:

    • U+2409SYMBOL FOR HORIZONTAL TABULATION
    • U+240BSYMBOL FOR VERTICAL TABULATION

    Why Does Pressing Tab Generate Key Event Mean

    Unicode also has characters for the symbols to represent or be printed on the tab key:[14]

    • U+21B9LEFTWARDS ARROW TO BAR OVER RIGHTWARDS ARROW TO BAR (tab with shift tab)
    • U+21C6LEFTWARDS ARROW OVER RIGHTWARDS ARROW
    • U+21E4LEFTWARDS ARROW TO BAR (leftward tab)
    • U+21E5RIGHTWARDS ARROW TO BAR (rightward tab)

    See also[edit]

    • Comma-separated values (CSV)

    References[edit]

    1. ^'Underwood Portable Typewriter Gallery'. Archived from the original on 2011-02-22. Retrieved 2011-04-09.
    2. ^'Instructions for Using the Underwood Typewriter'(PDF). Retrieved 2011-04-09.
    3. ^Fredric W. Hillard, Type-writing machine, U.S. Patent 720,520, granted Feb. 10, 1903.
    4. ^Harry S. Dukes and William H. Clayton, Tabulating mechanism for type-writing machines, U.S. Patent 908,221, granted Dec. 29, 1908.
    5. ^Edward B. Hess, Writing Machine, U.S. Patent 931,305, granted Aug. 17. 1909.
    6. ^James F. Koca, Typewriter stop mechanism, U.S. Patent 2,358,517, granted Sep. 19, 1944.
    7. ^Gravgaard, Nick. 'Elastic tabstops - a better way to indent and align code'. nickgravgaard.com. Retrieved 23 March 2018.
    8. ^See Character encodings in HTML#HTML character references
    9. ^'Character Entity Reference Chart'. dev.w3.org. Retrieved 23 March 2018.
    10. ^'CSS 3 tab-size property W3 specification'.
    11. ^'CSS tab-size property on Mozilla Developer Network'.
    12. ^'Extensible Markup Language (XML) 1.0' (5th ed.). W3C. 26 November 2008. sec. 'Charsets'.
    13. ^'C0 Controls and Basic Latin'(PDF). Retrieved 2013-12-13.
    14. ^'Arrows – Unicode'(PDF). Retrieved 2013-12-13.

    External links[edit]

    • Tabs versus Spaces: An Eternal Holy War by Jamie Zawinski
    • Why I prefer no tabs in source code by Adam Spiers
    • Why I love having tabs in source code (archived)
    IBM PC keyboard (Windows, US layout)
    Esc F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 PrtScn/
    SysRq
    Scroll
    Lock
    Pause/
    Break
    Insert Home PgUp Num
    Lock
    Delete End PgDn 7 8 9 +
    4 5 6
    1 2 3 Enter
    0
    Ins
    .
    Del
    Retrieved from 'https://en.wikipedia.org/w/index.php?title=Tab_key&oldid=945451228'

    There are two types of indents that can be adjusted: paragraphs and bullet points. Each has a separate way of adjusting the indent size. Below are the different ways you can adjust the indentation in Microsoft Word.

    • First line indent with tab.
    • Indent paragraph with shortcut key.
    • Adjusting indents using the ruler.
    • Changing indents in the Paragraph window.
    • Adjust the indent on the Ribbon in Word 2007 and later.
    • Adjusting the bullet and numbering indentation.

    First line indent with tab

    The first line indent can always be created using the Tab key on the keyboard. To change the first line indent size or indent the full paragraph, continue reading the below suggestions.

    Indent paragraph with shortcut key

    A complete paragraph can be indented with the keyboard shortcutCtrl+M and pressing the keyboard shortcut more than once will indent the paragraph further.

    Tip

    Why Does Pressing Tab Generate Key Event

    To reverse the indent, you can also press Ctrl+Shift+M.

    Adjusting indents using the ruler

    Key

    To adjust a paragraph indent size, use the Ruler, which is below the menu bar and resembles the picture shown below. If this feature is not visible, see our document on how to enable the Ruler.

    Towards the left side of the Ruler, look for indent markers that resemble an hourglass, like the image shown below.

    The top marker (down arrow) controls the first line indent, and the middle marker (up arrow) controls the hanging indent (the indent for lines after the first line in each paragraph). The bottom marker (small box) controls the left indent. To adjust these indents, you can click-and-drag each marker to the right or left.

    Tip

    To change the indentation for an entire document, select all text in the document (press Ctrl+A), then adjust the indent spacing in the ruler as detailed above.

    Note

    If a large indent is created when pressing the Tab key and adjusting the indent on the Ruler doesn't work, adjust the Left Tab Stop in the Ruler.

    Changing indents in the Paragraph window

    Another way to adjust the indents is to view the Paragraph settings. To view this window, double-click the markers in the ruler, click Format and then Paragraph. You can also place the cursor in the paragraph, right-click with your mouse, and chose Paragraph.

    As seen below in the Paragraph window, under the Indentation section, the left and right indent settings can be adjusted. You can also adjust the first line indent and hanging indent size under the Special option in the Indentation section.

    At the bottom of the Paragraph settings window, you can preview the look of the indent sizes you are setting and make changes accordingly until you get it the way you want.

    Adjust the indent on the Ribbon in Word 2007 and later

    If you're using a newer version of Microsoft Word that uses the Ribbon, such as Word 2007 or 2013, do the following.

    1. Click the Layout or Page Layout tab.
    2. Adjust the indent settings in the Paragraph section.

    To view the Paragraph window mentioned in the above section, click the small down arrow indicated by the red arrow in the picture below.

    Adjusting the bullet and numbering indentation

    Tip

    The easiest method of adjusting the bullets and number list in all versions of Word is to adjust the left indent through the Microsoft Word ruler bar.

    Note

    To adjust the spacing between the bullet and the text in a list, you may need to adjust the Left Tab Stop in the Ruler.

    Microsoft Word 2007, 2010, and later

    Why Does Pressing Tab Generate Key Event 2017

    1. Click on one of the bullets at the level you want to change in the document.
    2. Right-click the bullet and select Adjust List Indents in the pop-up menu.
    3. In the Adjust List Indents window, change the Bullet position to adjust the bullet indent size or change the Text indent to adjust the text indent size after a bullet.

    Microsoft Word 2000 and earlier

    1. Place your cursor in a bulleted or numbered line in the document.
    2. Click the Format menu at the top of the Word program and select the Bullets and Numbering option.
    3. In the Bullets and Numbering window, click the Customize button on one of the first three tabs, depending on the type of list you are changing.
    4. In the window that opens, adjust the indent size for the bullet position and the text position. At the bottom of the window, you can preview how the indentation sizing looks and make changes accordingly until you get it the way you want.

    You can also access the Bullet and Numbering window by placing your text cursor on a bulleted or numbered line and right-clicking in the Word document. In the pop-up menu, select the Bullets and Numbering option.

    Additional information

    Why Does Pressing Tab Generate Key Event Center

    • See our bullet and indent definitions for related information and links.





Designed by Tistory.