• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 283
  • Last Modified:

curses to draw a box

hi experts,

i am trying to draw a closed thick box. however the use of characters like hypens, pipes, or underscore cannot give me a closed thick box.

how?
0
sonic2000
Asked:
sonic2000
  • 3
  • 2
1 Solution
 
wesly_chenCommented:
Hi,

    You mean draw a thick box in a text editor like vi?
How about use "#" instead?

Wesly
0
 
sonic2000Author Commented:
i need a thick closed border box.
anyway what does it got to do with the text editor i am using? anyway i am using vim.
0
 
wesly_chenCommented:
Hi,
 
   vim is advanced version of vi.

   However, with text editor, which deals with ASCII code, it's hard to draw a closed box.
However, you can use "+" at each corner of the box.

Wesly
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
sonic2000Author Commented:
i read about ACS_BLOCK.
How to use all those color constants and drawings?
doesn't seem to work.
0
 
wesly_chenCommented:
Hi,

   ACS_BLOCK is a parameter for programming fuctions which are defined in ocurses.h.
It's not for plain text file.

Wesly
0
 
stefan73Commented:
Hi sonic2000,
If you have a colour display, you can use VT220 colour codes (or invert mode for monochrome) to exchange foreground and background colours:

Colour swapping:
"\x1b[30;47m"

Inverse: "\x1b[7m"

Reset to normal: "\x1b[0m"

See also http://rtfm.etla.org/xterm/ctlseq.html

Cheers!

Stefan
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now