Commit Graph

19 Commits

Author SHA1 Message Date
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
christos f90bcf3a23 - sprinkle const.
- avoid variable shadowing.
2005-05-29 21:56:35 +00:00
jmmv 92f81ea7d3 Implement support to dynamically change wscons console and kernel colors.
Two new ioctls are added to the wsdisplay device, named WSDISPLAY_GMSGATTRS
and WSDISPLAY_SMSGATTRS, used to retrieve the actual values and set them,
respectively (the name, if you are wondering, comes from "message attributes").

A new emulop is added to the underlying display driver (only vga, for now)
which sets the new attribute for the whole screen, without having to clear
it.  This is optional, which means that this also works with other drivers
that don't have this new operation.

Five new kernel options have been added, although only documented in
i386 kernels (for now):
- WSDISPLAY_CUSTOM_OUTPUT, which enables the ioctls described above to
  change the colors dynamically from userland.  This is enabled by default
  in the GENERIC kernel (as well as others) but disabled on all INSTALL*
  kernels (as this feature is useless there).
- WS_DEFAULT_COLATTR, WS_DEFAULT_MONOATTR, WS_DEFAULT_BG and WS_DEFAULT_FG,
  which specify the default colors for the console at boot time.  These have
  the same meaning as the (already existing) WS_KERNEL_* variables.

wsconsctl is modified to add msg.default.{attrs,bg,fg} and
msg.kernel.{attrs,bg,fg} to the display part, so that colors can be changed
after boot.

Tested on NetBSD/i386 with vga (and vga in mono mode), and on NetBSD/mac68k.
No objections in tech-kern@.
2004-07-28 12:34:02 +00:00
itojun db9226c772 use bounded string ops 2004-04-23 21:29:16 +00:00
drochner ef369e0ed6 remove license clauses 3 and 4 from my cpoyright notices 2004-03-24 17:26:53 +00:00
drochner 9ec3975139 allow to customize how highlighting and underlining text is substituted
if the display doesn't provide this
submitted by xs@kittenz.org per PR kern/18004
2003-04-02 18:22:56 +00:00
drochner f9773705b1 fix crash due to wrong argument in the (almost useless)
DECRQUPSS escape sequence
2003-04-02 17:48:59 +00:00
simonb 276fd1665c The Double-Semi-Colon Police. 2003-01-20 05:29:53 +00:00
junyoung 3d826105dc alloc_attr -> allocattr
Approved by Matthias Drochner.
2002-07-04 14:37:10 +00:00
lukem 139747fb15 add/cleanup RCSIDs 2001-11-13 06:17:46 +00:00
augustss 82e5e6ab85 ANSIfy. 2001-10-13 15:56:15 +00:00
cgd 023e9f0649 C requires that labels be followed by statements. 2001-02-24 00:01:22 +00:00
mycroft 73ac8c709b Add a concept of the `background attribute'. This is the same as the
current attribute, but has all non-color flags turned off.  Use this when
doing erasure, as this allows us to optimize repainting in curses.

XXX The way the default attribute is handled is totally bogus and needs to
be fixed.
2000-04-28 21:56:16 +00:00
mycroft 2fd2b78c1f Only call the cursor method when the cursor state is actually changing.
This avoid corrupting VGA displays in text mode (e.g. the first character
of the prompt when you exit vi).
2000-02-25 17:42:51 +00:00
augustss b2acf0b9f2 Change from bcopy/bzero to memxxx. From PR 6778 by
Erik Bertelsen <erik@q610.ebe.uni-c.dk>.
1999-01-10 00:28:21 +00:00
drochner 8e12b6c020 stricter parameter check for scrolling regions
(PR kern/5954 by Dave Huang <khym@bga.com>)
1998-08-12 20:04:12 +00:00
drochner 02e2e73771 fix VT300 tab stop report format 1998-06-29 21:14:40 +00:00
drochner bbb4f765cc Improvements to the VT100 emulation:
-display DEC special graphics and DEC technical characters as far as
  possible
-implement the font switching controls (need documentation!)
-behave well if double-width characters are requested
-simplify the state machine: store CSI command modifiers in variables
  instead of dedicating own states to each of them
1998-06-26 21:20:34 +00:00
drochner 68aabb6d21 First cut on a VT100 emulation.
It should be able to parse escape sequences up to VT300, but not everything
is implemented. Most notably, there is no font handling - all displayable
characters are handed to the graphics driver. To solve this, a serious
interface change to the graphics driver is needed (Unicode?).
1998-06-20 19:17:47 +00:00