- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- How to draw a box on the screen?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 07:13 AM
06-13-2003 07:13 AM
I have to update some old shell scripts and make them look nice. Is there a method to draw a box around some text in the shell? I suppose that I could live with +'s for the corners, abd dashes and pipe symbols but I would really like to able to draw nice lines like SAM does. Any hints or ideas?
TIA,
Bob Fisher
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 07:18 AM
06-13-2003 07:18 AM
Re: How to draw a box on the screen?
As far as I know, they are done with curses/ncurses. You have to do a bit of C programming to achieve what you want.
see man curses for further info.
HTH,
Umapathy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 07:19 AM
06-13-2003 07:19 AM
Re: How to draw a box on the screen?
You can write in difrent modes,
about a screens you can draw special characters
(ASCII draw) depend on the font that you use.
I think that exist tools that creates screens
like SAM screens.
Caesar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 07:26 AM
06-13-2003 07:26 AM
Re: How to draw a box on the screen?
The key to what you want is the tput smacs command. (Start alternate character set). That sequence is not defined for all terminals so you need a fallback plan using "+","-", & "|" in case the smacs sequence is null. At a minimum the cursor position string and the clear string would also be needed. At best this will be a kludge.
There are some Perl modules that do curses rather well and also Perl/Tcl if you really wanted to modernize but still script.
I do remember doing something like this about 20 years ago. I'll look in my toolbox for the old script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 07:48 AM
06-13-2003 07:48 AM
Re: How to draw a box on the screen?
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 08:02 AM
06-13-2003 08:02 AM
SolutionMan 4 terminfo and look for "Line Graphics" for details.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 08:38 AM
06-13-2003 08:38 AM
Re: How to draw a box on the screen?
Clay, I'm amazed that you keep scripts that are 12 years old around.
Thanks again,
Bob Fisher
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 08:46 AM
06-13-2003 08:46 AM
Re: How to draw a box on the screen?
Regards, Clay
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-13-2003 09:06 AM
06-13-2003 09:06 AM
Re: How to draw a box on the screen?
I laughed so hard at your last response that I had to give you 10 points!! I remember that cartoon too.
Thanks,
Bob Fisher