DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 9th June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default [OpenBSD] Customize Xenodm (background image , change keyboard , change xterm)

how i can change background image(png,jpg ...) in xenodm ?
how i can change keyboard layout by press ALT + Shift ?
how i can change background , foreground , font size and font family of xterm console ?
anything must be permanents.

thanks.
Reply With Quote
  #2   (View Single Post)  
Old 9th June 2020
d31n1 d31n1 is offline
Port Guard
 
Join Date: Jan 2020
Posts: 14
Default

I would check out
https://www.tumfatig.net/20190208/cu...penbsd-xenodm/
and
https://www.c0ffee.net/blog/openbsd-on-a-laptop/
under section X11 is and .Xresources example
Reply With Quote
  #3   (View Single Post)  
Old 9th June 2020
Head_on_a_Stick's Avatar
Head_on_a_Stick Head_on_a_Stick is offline
Real Name: Matthew
Bitchy Nerd Elitist
 
Join Date: Dec 2015
Location: London
Posts: 465
Default

It's probably better to use ~/.Xdefaults to configure xterm rather than ~/.Xresources because it doesn't require that the resources be reloaded when they're changed. Note that xterm will only read ~/.Xdefaults if ~/.Xresources doesn't exist.

Anyway, here's my sample file:

https://raw.githubusercontent.com/He...ster/Xdefaults

^ That uses the stock bitmap font, to apply an XFT font use
Code:
Xterm*vt100.faceName: mono:size=11
__________________
Are you infected with Wetiko?
Reply With Quote
  #4   (View Single Post)  
Old 10th June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

thanks to all.

but according to your posts i can not change background image and keyboard layout by ALT + SHIFT keys.


for changing keyboard layout i find this code :
Code:
setxkbmap -layout us,it -option grp:alt_space_toggle
but alt_shift_toggle not working.

how i can set that permanent?
how i can change background image? [login + desktop]
Reply With Quote
  #5   (View Single Post)  
Old 10th June 2020
Prevet Prevet is offline
Shell Scout
 
Join Date: Oct 2017
Posts: 84
Default

feh can change background image.
Install feh and see the man page.
Put this in your .xsession file
feh --bg-fill --no-fehbg --randomize --recursive ~/pictures

There was a post here about customizing the login
https://www.reddit.com/r/openbsd/com...xenodm_themes/
Reply With Quote
  #6   (View Single Post)  
Old 10th June 2020
bsdun bsdun is offline
Real Name: Steve
Fdisk Soldier
 
Join Date: Feb 2020
Posts: 48
Default

(In many programs Alt is called "Meta"; Windows Key is called "Mod" or "Mod4".)
ALT-SHIFT:
in ~/.xsession file
Code:
setxkbmap -model pc104 -layout us,it -variant ,, -option grp:alt_shift_toggle
If you want the NumLock to be turned on automatically, install numlockx:
Code:
pkg_add numlockx
Then add it to ~/.xsession:
Code:
/usr/local/bin/numlockx on
All those lines in ~/.xsession should be above the line that invokes window manager/desktop environment.
Reply With Quote
  #7   (View Single Post)  
Old 22nd June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

Quote:
Originally Posted by Head_on_a_Stick View Post
It's probably better to use ~/.Xdefaults to configure xterm rather than ~/.Xresources because it doesn't require that the resources be reloaded when they're changed. Note that xterm will only read ~/.Xdefaults if ~/.Xresources doesn't exist.

Anyway, here's my sample file:

https://raw.githubusercontent.com/He...ster/Xdefaults

^ That uses the stock bitmap font, to apply an XFT font use
Code:
Xterm*vt100.faceName: mono:size=11
background changed but font size not changed.
Reply With Quote
  #8   (View Single Post)  
Old 22nd June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

Quote:
Originally Posted by Prevet View Post
feh can change background image.
Install feh and see the man page.
Put this in your .xsession file
feh --bg-fill --no-fehbg --randomize --recursive ~/pictures

There was a post here about customizing the login
https://www.reddit.com/r/openbsd/com...xenodm_themes/
i install feh but when i add this config in .xsession and re-login then OpenBSD shown blank page and return to login page(no desktop loaded). (i fix this problem in boot by removing .xsession file)
also i set .xsession permission to 777.

but when run this command in xterm then background changed.
Code:
feh --bg-fill --no-fehbg --randomize --recursive ~/pictures
Reply With Quote
  #9   (View Single Post)  
Old 23rd June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

not working.
Reply With Quote
Old 23rd June 2020
shep shep is offline
Real Name: Scott
Arp Constable
 
Join Date: May 2008
Location: Dry and Dusty
Posts: 1,507
Default

The feh project provides a specific tool for single image wallpapers: ~/.fehbg. It is generated with
Code:
feh --bg-fill wallpaper.png
run in your home directory.
Scale it once and then run ./fehbg in your .xsession or autostart file.
Reply With Quote
Old 23rd June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

Quote:
Originally Posted by Prevet View Post
Post your .xsession file. Also take a look at the .xsession files in the links I posted, and try to figure out how yours is different. I am thinking you might have started your window manager before you started feh. The window manager call should be the last command in your .xsession file.

This is a command that shows one picture.

feh --bg-scale --no-fehbg ~/pictures/filename.jpeg &
/root/.xsession file is empty and i edit this file to :
Code:
feh --bg-fill --no-fehbg --randomize --recursive ~/pictures
but not working.

I'm a beginner in OpenBSD. Please post full description ...
Reply With Quote
Old 23rd June 2020
bsdun bsdun is offline
Real Name: Steve
Fdisk Soldier
 
Join Date: Feb 2020
Posts: 48
Exclamation Don't use root as your default user!

Quote:
Originally Posted by jonsec View Post
/root/.xsession file is empty ...
Are you using OpenBSD as root? You should create your own user, add that user to groups wheel, staff, operator; set up doas.conf to give your user permission to run as root through doas
(example: doas pkg_add ranger)
doas.conf should end with an empty line at the end of file, or you'll get error.
Read these articles:
https://man.openbsd.org/useradd
https://man.openbsd.org/usermod
https://man.openbsd.org/doas
https://man.openbsd.org/doas.conf
Reply With Quote
Old 23rd June 2020
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

The operator group provides read access to all filesystems/storage, which should be a security concern when not being used for backup. Do you trust every third party program you install?
Reply With Quote
Old 23rd June 2020
bsdun bsdun is offline
Real Name: Steve
Fdisk Soldier
 
Join Date: Feb 2020
Posts: 48
Default

Quote:
Originally Posted by jggimi View Post
Do you trust every third party program you install?
That's a good question. I need to think about it.
Reply With Quote
Old 23rd June 2020
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

A typical workstation will have hundreds of dependencies automatically installed, and most users don't think twice about them.

Time to think twice.
Reply With Quote
Old 23rd June 2020
jonsec jonsec is offline
Fdisk Soldier
 
Join Date: Jul 2019
Posts: 71
Default

Quote:
Are you using OpenBSD as root?
yes. i not want to use another account.

Quote:
You should create your own user, add that user to groups w...
why?
i can run feh command in root account(in xterm) and works.
Reply With Quote
Old 23rd June 2020
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

  1. A typographic error, confusion about your working directory, or other jonsec-caused error could damage the OS or make it unusable, even unrecoverable.
  2. You are giving ALL of the scripts and executable programs on your workstation the authority to do ANYTHING. Note my comments above about the excessive authority of the operator group for normal use. That is dangerous. This is worse.
Reply With Quote
Old 24th June 2020
PapaParrot's Avatar
PapaParrot PapaParrot is offline
parrot
 
Join Date: Jul 2015
Location: Durango, Mx.
Posts: 472
Default

Quote:
Originally Posted by Prevet View Post
Post your .xsession file. Also take a look at the .xsession files in the links I posted, and try to figure out how yours is different. I am thinking you might have started your window manager before you started feh. The window manager call should be the last command in your .xsession file.

This is a command that shows one picture.

feh --bg-scale --no-fehbg ~/pictures/filename.jpeg &
This topic has gotten rather confusing, but any way, here is my .xsession file, works good for me.
.xsession:
Code:
tint2 &
./background &
xrdb -load .Xresources &
xterm &
fluxbox
Note, "background" is a executable script I have, :
Code:
display -window root /home/garry/Images/backgrounds/aa-OBSD-background.png
That's all there is to it, I am using 'display' instead of 'feh', but 'feh' works just as well, and if it is for the login window, or console, it needs to be 'feh' , 'display' will not work.
__________________
My best friends are parrots
Reply With Quote
Old 24th June 2020
PapaParrot's Avatar
PapaParrot PapaParrot is offline
parrot
 
Join Date: Jul 2015
Location: Durango, Mx.
Posts: 472
Default

I used this: https://www.tumfatig.net/20190208/cu...penbsd-xenodm/ tutorial,
posted by d31n1
I don't know how to capture a screen shot of the login window,.. so I put the image on a VM, and also just copied my Xsetup_0 file , to the VM, then took a screen shot of the VM
==============================================
__________________
My best friends are parrots
Reply With Quote
Old 24th June 2020
fvgit's Avatar
fvgit fvgit is offline
Spikes in tights
 
Join Date: May 2016
Location: perl -MMIME::Base64 -le 'print decode_base64("U2hlcndvb2QgRm9yZXN0")'
Posts: 314
Default

Quote:
Originally Posted by PapaParrot View Post
I don't know how to capture a screen shot of the login window,..
Add the following line to the end the end of your /etc/X11/xenodm/Xsetup_0:
Code:
xwd -out /tmp/xenodm.xwd -root &
This will dump an image of your xenodm window in xwd format into your /tmp folder. You can then convert it to png or jpeg using sth. like ImageMagick or gimp to post it on the forum.
Reply With Quote
Reply

Tags
background, language, xenodm, xterm


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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Operational change required for OpenBSD -current users jggimi OpenBSD General 2 18th October 2016 02:19 PM
Any info on OpenBSD 5.6's new default IPv6 to off change? SlyM OpenBSD General 4 2nd November 2014 09:45 PM
How to change keyboard key? newbsdied OpenBSD General 5 7th November 2010 02:45 AM
How to change the font size? atop xterm, aterm, etc jb_daefo General software and network 12 13th July 2010 10:42 AM
Can not change keyboard layout with SHIFT and Alt after VNCviewer connect mfaridi OpenBSD General 1 13th December 2008 03:14 PM


All times are GMT. The time now is 10:53 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick