LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 06-02-2006, 10:36 AM   #1
Muraii
Member
 
Registered: May 2006
Posts: 65

Rep: Reputation: 15
XTerm Customization Problems


I've been slowly accreting a system that fits me. I installed a somewhat lean 10.2, eschewing KDE and all the window managers and duplicate applications (how many text editors does one really need?). I have installed OpenBox3 and pypanel (and tried to install adesklets, but for some reason it won't...yet), and put together a simple interface with a few custom keybindings and right-click menu items, for the necessities: firefox; xterm; ObConf; ROX-filer.

Now, I'm just about done with the customizations. I've changed the background color for xterm, and have been trying to change the LS_COLORS environment variable so things look right. I'm having a couple of issues, though:

(1) The background color for xterm worked fine...except that, this morning, I noticed that when I highlight anything in Firefox (and maybe in general, but I've only been highlighting in Firefox since having changed xterm's settings), and switch back to an open xterm window, the background has been changed back to white...except for behind the prompt and any rendered text.

(2) I've read man dir_colors and man dircolors, found /etc/DIR_COLORS and copied it as ~/.dir_colors. That didn't seem to work, so I made a backup of /etc/DIR_COLORS then changed the values in it, but that didn't seem to work, either. Note that I have quit and restarted X with each change, to reload the variable (though there's probably a smarter way to do it), so it isn't that. I even ran dircolors -P (the man page says the switch should be lowercase, but it wasn't recognized while the uppercase was) and found that the correct colors are in dircolors' internal database (or so it would seem). No luck.

I know xterm isn't the most customizable X terminal, but it works well enough. I might install aterm or rxvt if it seems a better fit, but I'd like to see if I can avoid quitting on xterm. It occurs to me, as I write this, that maybe I should change the alias for ls from ls -color=auto to something else, but I assume the "auto" refers to the environment variable, which I thought I'd changed.

Does anyone have any recommendations?
 
Old 06-02-2006, 10:48 AM   #2
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
I was reading somewhere else, and it occurred to me: do I need to issue eval `dircolors -b` to output to LS_COLORS? That's already in /etc/profile, so I assume it's run when X launches, but I'm not sure.
 
Old 06-02-2006, 01:03 PM   #3
Old_Fogie
Senior Member
 
Registered: Mar 2006
Distribution: SLACKWARE 4TW! =D
Posts: 1,519

Rep: Reputation: 63
I dont have an answer, was just reading your thread and I agree way too much choice in slackware default LOL.

I too have been going lean and mean. I wish I could see how Open box worked. Any chance of you giving some pointers on this after your done?

Check out the amigo site by the way, it's pretty cool for us lean and mean guys.

I'm on zipslack on a few pc's w/blackbox. I like it but I cant find where stuff goes when I minimize too good.
 
Old 06-02-2006, 01:49 PM   #4
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Old_Fogie
I dont have an answer, was just reading your thread and I agree way too much choice in slackware default LOL.
If I have choice, I'm a mess. No discipline.

Quote:
I too have been going lean and mean. I wish I could see how Open box worked. Any chance of you giving some pointers on this after your done?
Completely. It's really very simple to work with. Two XML files for your settings.

Quote:
Check out the amigo site by the way, it's pretty cool for us lean and mean guys.
I'll have to. I've never heard of it.

Quote:
I'm on zipslack on a few pc's w/blackbox. I like it but I cant find where stuff goes when I minimize too good.
I thought about going ZipSlack to begin with, but I figured I'd just make sure not to install too much junk.

Are you using a panel with Blackbox? I have something with enough transparency to stay out of the way, but with enough opacity to offer a little visual appeal and show minimized windows. I'd like an option that only shows the icon or only the app name, and not both; but it's only 24 pixels high so it's no big deal. It's pypanel, if you're interested.
 
Old 06-02-2006, 02:31 PM   #5
Old_Fogie
Senior Member
 
Registered: Mar 2006
Distribution: SLACKWARE 4TW! =D
Posts: 1,519

Rep: Reputation: 63
Hi.

No just blackbox. I found the pypanel on amigo's site.

there address is: http://amigolinux.org/

tho i havent had a chance to try it out yet.

i just moved over to zip slack and started using the black box. it's so fast for old pc's i really like it.

but it does need some kind of panel.
 
Old 06-02-2006, 09:37 PM   #6
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
Well, I kind of have it working okay. I have loaded LS_COLORS for my regular user account with the colors I want, and then reverted the /etc/profile to normal so my root account has some coloring. I need to set things up for root in XTerm, though, because root colors only work in console because I don't have the alias for ls set up. I assume putting it in [I]/root[I] isn't the appropriate place to put root-specific attribute customization.

I had worked up a bash script in /etc/profile.d/, but I kept getting errors that arose, I'm sure, from my lack of familiarity with shell scripts. That'll come.

The solution, though, was just to get [I]eval `dircolors ~/.dir_colors -b` to actually execute in an automated fashion. That's what was in the bash script, as well as some stuff to get my prompt to vary by uid and also by whether or not I was interacting with bash via an xterm or the system console, but it didn't really work out, as I mentioned. But LS_COLORS is maintained inside dircolors database, so if you run $ eval `dircolors path_to_file/colors_file -b`, and have the right stuff in that file, it should remember it thereafter.

It's not terribly clear, but hopefully helpful nonetheless.
 
Old 06-03-2006, 12:04 AM   #7
detpenguin
Senior Member
 
Registered: Oct 2003
Location: lost in the midwest...
Distribution: Slackware
Posts: 1,098

Rep: Reputation: 54
i created a file in my home directory called .Xdefaults, then i added this:
Quote:
xterm*cursorColor:blue
xterm*colorMode:true
xterm*pointerColor:yellow
xterm*pointerColor2:yellow
xterm*borderWidth:0
xterm*tinting:#ffffff
xterm*loginShell:true
xterm*transparent:true
xterm*shading:80
xterm*background:#dcdcdc
xterm*foreground:#800000
xterm*scrollBar:false
xterm*fade: 60
!xterm*font: 9x15
xterm*font: 8x13
xterm*saveLines:4500
xterm*geometry:85x30
xterm*truetintingType:True
!
! colors
!
xterm*color0:rgb:00/00/00
xterm*color1:rgb:cc/66/66
xterm*color2:rgb:66/cc/66
xterm*color3:rgb:cc/cc/66
xterm*color4:rgb:66/66/cc
xterm*color5:rgb:cc/66/cc
xterm*color6:rgb:66/cc/cc
xterm*color7:rgb:cc/cc/cc
xterm*color8:rgb:63/33/33
xterm*color9:rgb:ff/99/99
xterm*color10:rgb:99/ff/99
xterm*color11:rgb:ff/ff/99
xterm*color12:rgb:99/99/ff
xterm*color13:rgb:ff/99/ff
xterm*color14:rgb:99/ff/ff
xterm*color15:rgb:ff/ff/ff
it's a decent start, and easily modified....maybe this will help you get where you're going?
 
Old 06-03-2006, 05:40 AM   #8
pdw_hu
Member
 
Registered: Nov 2005
Location: Budapest, Hungary
Distribution: Slackware, Gentoo
Posts: 346

Rep: Reputation: Disabled
"I'm on zipslack on a few pc's w/blackbox. I like it but I cant find where stuff goes when I minimize too good."

Middleclick on desktop -> iconified windows
 
Old 06-03-2006, 01:06 PM   #9
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by detpenguin
i created a file in my home directory called .Xdefaults, then i added this:

it's a decent start, and easily modified....maybe this will help you get where you're going?
I didn't know there were that many parameters that you could set up. Thanks for the tip. Also, have you had any problems with the xterm window redrawing with the default color everywhere except behind the text? It's not mission critical, or anything; but it's annoying. Sometimes it happens when I minimize then maximize, sometimes it happens when I've switched windows. I haven't really discerned a pattern, because it also doesn't happen sometimes when those things are done.

Again, though, thanks.
 
Old 06-03-2006, 05:50 PM   #10
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
detpenguin, you did it. Telling XTerm to use a loginShell was the key. Now, my customize.sh sets up a PS1 variable that knows whether or not I'm at a system console or an xterm, and in the former case gives me my full prompt with user- and hostname, while in the latter case the user- and hostnames and working directory are in the window title.

The only thing I need to figure out now is how to make this behavior work when I log into the root account from the user account, i.e. give me the red prompt to alert me to my being super user whether or not I'm logging in to the system from a login prompt or by issuing su.

Anyone know how to make bash scripts in /etc/profile.d/ execute when logging in via su?

If not, no big deal. I'll figure out something (maybe a .bashrc in /root).

Daniel
 
Old 06-03-2006, 09:42 PM   #11
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
So, taking that logic that determines whether I'm using a console or xterm, and putting it in /root, did the trick. I really hope this is helpful to someone, because I'm blathering on a bit about colorized prompts.
 
Old 06-04-2006, 02:57 AM   #12
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
You might try using xtermcontrol which you can get from my site. You could write a wrapper for your terminal which would set up your environment before starting it.

As for a panel, I prefer to not use Python, so pypanel is out. What I use with WindowMaker is taskbar (1.0.3 does LM sensors) or fbpanel-2.2, which supports gnome-applets(I think). An even lighter panel is fspanel.
 
Old 06-05-2006, 11:17 PM   #13
Muraii
Member
 
Registered: May 2006
Posts: 65

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by gnashley
You might try using xtermcontrol which you can get from my site. You could write a wrapper for your terminal which would set up your environment before starting it.
Thanks. I eventually will use some more automation, but I'd like to know what it is I'm automating.

Quote:
Originally Posted by gnashley
As for a panel, I prefer to not use Python, so pypanel is out. What I use with WindowMaker is taskbar (1.0.3 does LM sensors) or fbpanel-2.2, which supports gnome-applets(I think). An even lighter panel is fspanel.
I'll take a look. Thanks. Why the aversion to Python?

Last edited by Muraii; 06-05-2006 at 11:20 PM.
 
Old 06-06-2006, 01:35 AM   #14
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
My 'fast' computer is a PentiumII 333MHz.Python chokes it up terribly.
I used to use a python-based 'runbox' which took around 5 seconds to start. grun or gtk-launcher, both for GTK-1.2 start in a half-second.

Studying the documentation for xtermcontrol will probably help you understand better what xterm can and can't do, and how. I haven't really used it yet -I've only run the demos. But they are pretty impressive.

If you are putting together your own light-weight desktop, you definitely should look all over my download site. Start in GUIcomponents for the basics like window managers, panels, menu tools, etc:
http://distro.ibiblio.org/pub/linux/...GUIcomponents/

Even if you choose to use my binary packages or not use my sources at all, I've tried to put useful stuff together in the same area, and anything extra for a certain program will be in a subdir called Resources inside the source directory. Often there are patches there, or tips that I have found, accessory programs, etc.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
xterm - howto lauch an xterm into a specific directory jobano Linux - Software 11 01-30-2023 04:45 AM
xterm customization Flexxy Linux - Software 9 02-06-2006 08:27 PM
how is black xterm background in IceWM when issue a xterm command? BRAHmS Linux - Software 1 02-14-2005 03:51 AM
xterm problems alaios Linux - General 11 10-10-2004 01:41 AM
Gnome2 customization problems yngwin Linux - Software 0 12-19-2002 07:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration