JWM tray clock fonts [SOLVED]

Using applications, configuring, problems
Post Reply
Message
Author
User avatar
mavrothal
Posts: 3096
Joined: Mon 24 Aug 2009, 18:23

JWM tray clock fonts [SOLVED]

#1 Post by mavrothal »

I would like to change the JWM tray clock (minixcal) fonts but without changing the puppy fonts globally or the JWM fonts globally.
So the, previously reported in other similar questions, changes through the global font size and JWM font size, are out. I would like just the minixcal's fonts changed.

I could not find anything in the forum and looking at the minixcal-1.1 code I could not see any gtk get_font call. Only a get_style call which I assume it inherits the GtkWidget settings ie the global settings.

Do I miss something? Is it possible to change minixcal's fonts only without affecting other fonts or minixcal needs a rewrite to support this?

Thx

PS: I do not really care about any other tray clock that may be capable of that...
Last edited by mavrothal on Fri 16 Nov 2012, 18:15, edited 2 times in total.
== [url=http://www.catb.org/esr/faqs/smart-questions.html]Here is how to solve your[/url] [url=https://www.chiark.greenend.org.uk/~sgtatham/bugs.html]Linux problems fast[/url] ==

User avatar
ETP
Posts: 1193
Joined: Tue 19 Oct 2010, 19:55
Location: UK

Re: Tray clock (minixcal) fonts

#2 Post by ETP »

mavrothal wrote:I would like to change the JWM tray clock (minixcal) fonts but without changing the puppy fonts globally or the JWM fonts globally.
So the, previously reported in other similar questions, changes through the global font size and JWM font size, are out. I would like just the minixcal's fonts changed.
Hi mavrothal,
It depends on what you mean by "change", but this may suffice:
http://www.murga-linux.com/puppy/viewto ... 921#464921
Attachments
image-1.png
(35.82 KiB) Downloaded 1195 times
Regards ETP
[url=http://tinyurl.com/pxzq8o9][img]https://s17.postimg.cc/tl19y14y7/You_Tube_signature80px.png[/img][/url]
[url=http://tinyurl.com/kennels2/]Kennels[/url]

User avatar
mavrothal
Posts: 3096
Joined: Mon 24 Aug 2009, 18:23

#3 Post by mavrothal »

Thank you ETP,
PupClockset is a very nice app, but as I said originally I do not want to replace minixcal with some other clock.
As far as I remember this is what PupClockset does in JWM, replaces "minixcal" in /root/.jwmrc-tray with "PupClockset".
== [url=http://www.catb.org/esr/faqs/smart-questions.html]Here is how to solve your[/url] [url=https://www.chiark.greenend.org.uk/~sgtatham/bugs.html]Linux problems fast[/url] ==

Jasper

#4 Post by Jasper »

Hi mavrothal.

I made my adjustments at /root/.jwm/jwmrc-theme as in the screen shot, though I'm not at all sure if this is what you mean.

My regards
Attachments
image-1.png
(36.77 KiB) Downloaded 1051 times

User avatar
mavrothal
Posts: 3096
Joined: Mon 24 Aug 2009, 18:23

#5 Post by mavrothal »

Jasper wrote:Hi mavrothal.

I made my adjustments at /root/.jwm/jwmrc-theme as in the screen shot, though I'm not at all sure if this is what you mean.
Thank you Jasper.
I believe that this affects the entire tray, not just the clock.
What I would like is to have all fonts at puppy-default and just the clock fonts to be of different type and/or size. ie a minixcal-specific change.
== [url=http://www.catb.org/esr/faqs/smart-questions.html]Here is how to solve your[/url] [url=https://www.chiark.greenend.org.uk/~sgtatham/bugs.html]Linux problems fast[/url] ==

Jasper

#6 Post by Jasper »

Hi mavrothal,

So far as I have noticed my changes only apply to 'Menu' and my clock.

My regards

User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#7 Post by 01micko »

Code: Select all

<ClockStyle>
 <Font>Ionic Charge-16:weight=medium</Font>
</ClockStyle>
Put that in an include (jwmrc-personal will do) with the font you want. See http://joewing.net/programs/jwm/config.shtml#clock
Puppy Linux Blog - contact me for access

User avatar
ETP
Posts: 1193
Joined: Tue 19 Oct 2010, 19:55
Location: UK

Tray clock (minixcal) fonts

#8 Post by ETP »

Hi mavrothal & jasper,

Just to clarify this issue PupClockset only changes the font on the clock which I have just cranked up to 18 point.
jwmrc-theme then shows 18 in the ClockStyle section at the bottom: (no other fonts are changed)

Code: Select all

<JWM>

<WindowStyle>
    <Font>DejaVu Sans  -12</Font>
    <Width>3</Width>
    <Height>22</Height>     
    <Active>
       <Text>#ffffff</Text>
       <Title>#8fb2d8:#3f6fa9</Title>
<!--       <Corner>#8fb2d8</Corner> -->
       <Outline>#4e549f</Outline>
    </Active>
    <Inactive>
       <Text>#000000</Text>
       <Title>#3f6fa9:#8fb2d8</Title>         
<!--       <Corner>#3f6fa9</Corner> -->
       <Outline>#4e549f</Outline>
    </Inactive>
</WindowStyle> 

<TaskListStyle>
<Font>DejaVu Sans  -12</Font>
<ActiveForeground>#ffffff</ActiveForeground>
<ActiveBackground>#8fb2d8:#3f6fa9</ActiveBackground>
<Background>#3f6fa9:#8fb2d8</Background>
</TaskListStyle>

	<!-- TRAY PROPERTIES -->

	<TrayStyle>
		<Font>DejaVu Sans  -12</Font>
		<Foreground>#000000</Foreground>
		<Background>#a9b5c2</Background>
	</TrayStyle>

	<!-- PAGER PROPERTIES -->

	<PagerStyle>
		<Outline>grey</Outline>
		<Foreground>#8fb2d8</Foreground>
		<Background>#3f6fa9</Background>
		<ActiveForeground>#8fb2d8</ActiveForeground>
		<ActiveBackground>#3f6fa9</ActiveBackground>
	</PagerStyle>

	<PopupStyle>
		<Font>DejaVu Sans  -12</Font>
		<Outline>#4e549f</Outline>
		<Foreground>#000000</Foreground>
		<Background>#ffffff</Background>
	</PopupStyle>

	<MenuStyle>
		<Font>DejaVu Sans  -12</Font>
		<Foreground>#000000</Foreground>
		<Background>#a9b5c2</Background>
		<ActiveForeground>#ffffff</ActiveForeground>
		<ActiveBackground>#8fb2d8:#3f6fa9</ActiveBackground>
	</MenuStyle>

	<ClockStyle>
		<Font>Sans-18:bold:normal</Font>
		<Foreground>#000000</Foreground>
	</ClockStyle>

</JWM>
.jwmrc-tray (at the bottom) shows the format:

Code: Select all

<JWM>
	<Tray  autohide="false" insert="right" x="0" y="-1" border="1" height="32" >
		<!-- Additional TrayButton attribute: label -->
		<TrayButton label="" icon="logo-mini.png">root:3</TrayButton>
		<!-- Additional TrayButton attribute: label -->
		<TrayButton popup="Pfind" icon="/root/my-documents/Puppy icons/Search.png">exec:pfind</TrayButton>
		<TrayButton popup="Eject/Close" icon="/root/my-documents/Puppy icons/Eject.png">exec:eject -T</TrayButton>
		<TrayButton popup="Reboot" icon="/root/my-documents/Puppy icons/reboot.png">exec:wmreboot</TrayButton>
		<TrayButton popup="Power-Off" icon="/usr/local/PupControl/icons/shutdown24.png">exec:wmpoweroff</TrayButton>
		<TrayButton popup="PupSnap 1.8" icon="mini-camera.xpm">exec:PupSnap</TrayButton>
		<TrayButton popup="LXTask 0.1.4" icon="mini-run.xpm">exec:lxtask</TrayButton>
		<TrayButton popup="PupControl 2.2" icon="/usr/local/PupControl/icons/control-panel_20.png">exec:PupControl</TrayButton>
		<TrayButton popup="Nvidia-Settings" icon="/root/my-documents/Puppy icons/nvidia-settings.png">exec:/usr/bin/nvidia-settings</TrayButton>
		<!-- Additional Pager attributes; width, height -->
		<Pager/>
		<!-- Additional TaskList attribute: maxwidth -->
		<TaskList maxwidth="260"/>
		<Dock/>
		<!-- Additional Swallow attribute: height -->
	<!--	<Swallow name="blinky">
			blinkydelayed -bg "#a9b5c2"
		</Swallow> -->
	<!--	<Swallow name="xtmix-launcher">
			xtmix -launch
		</Swallow> -->
	<!--	<Swallow name="asapm">
			asapmshell -u 4
		</Swallow> -->
	<!--	<Swallow name="freememapplet" width="34">
			freememappletshell
		</Swallow> -->
		<Swallow name="xload" width="32">
			xload -nolabel -bg "#a9b5c2" -fg red -hl white
		</Swallow>
		<Clock format="%a %d %b %H:%M">PupClockset</Clock>
	</Tray>
</JWM>
Regards ETP
[url=http://tinyurl.com/pxzq8o9][img]https://s17.postimg.cc/tl19y14y7/You_Tube_signature80px.png[/img][/url]
[url=http://tinyurl.com/kennels2/]Kennels[/url]

Jasper

#9 Post by Jasper »

Hi ETP,

I'm sure you are right, except I think mavrothal is saying that
minixcal no longer works and I vaguely recollect that's why I
made my manual adjustment (so I could still click the clock).

My regards

User avatar
ETP
Posts: 1193
Joined: Tue 19 Oct 2010, 19:55
Location: UK

Tray clock (minixcal) fonts

#10 Post by ETP »

Jasper wrote:Hi ETP,

I'm sure you are right, except I think mavrothal is saying that
minixcal no longer works and I vaguely recollect that's why I
made my manual adjustment (so I could still click the clock).

My regards
Hi jasper,

You make a valid point. A possible alternative is a symlink in startup to usr/bin/osmo with run minimised selected in OSMO.
Mavrothal now has more options than he can shake a stick at, as he can click the "little man". :lol:
Attachments
image-2.png
(135.55 KiB) Downloaded 980 times
Regards ETP
[url=http://tinyurl.com/pxzq8o9][img]https://s17.postimg.cc/tl19y14y7/You_Tube_signature80px.png[/img][/url]
[url=http://tinyurl.com/kennels2/]Kennels[/url]

User avatar
mavrothal
Posts: 3096
Joined: Mon 24 Aug 2009, 18:23

#11 Post by mavrothal »

01micko wrote:

Code: Select all

<ClockStyle>
 <Font>Ionic Charge-16:weight=medium</Font>
</ClockStyle>
Put that in an include (jwmrc-personal will do) with the font you want. See http://joewing.net/programs/jwm/config.shtml#clock
Bingo!

Thank you all
== [url=http://www.catb.org/esr/faqs/smart-questions.html]Here is how to solve your[/url] [url=https://www.chiark.greenend.org.uk/~sgtatham/bugs.html]Linux problems fast[/url] ==

npierce
Posts: 858
Joined: Tue 29 Dec 2009, 01:40

#12 Post by npierce »

mavrothal wrote:I would like to change the JWM tray clock (minixcal) fonts . . .
First, to avoid confusion, understand that minixcal is not the JWM tray clock. The JMW tray clock is provided by JWM itself. minixcal is simply the command that is run when a user clicks on the tray clock -- the miniature calendar.

As mavrothal and Jasper have correctly pointed out, one side-effect of running PupClockset is that it replaces minixcal with itself as the command to run when the clock is clicked.

ETP has made the good suggestion of having Osmo automatically added to the tray when X starts, so a user can quickly access its calendar.

But if you prefer the little minixcal calendar, PopClockset 1.9.2 can be cured of its self-absorption by running the following command:

Code: Select all

sed -e "s/>PupClockset</>minixcal</g" -i /usr/local/PupClockset/func
You may, of course, want to first make a backup of /usr/local/PupClockset/func just in case something goes amiss.

After executing that command, run PupClockset and click the Set button. PupClockset will restart JWM and you should now be able to access minixcal again by clicking on the tray clock. (And you can still access PupClockset from Menu -> Desktop -> PupClockset manager, or from a command line.)

This works with JWM and PopClockset 1.9.2. It won't work with other window managers and I make no guarantees about other versions of PupClockset.


Of course, if all you really need to do is to change the font, and don't need any of the other benefits of PupClockset, the simple solution provided by 01micko is your best bet.

User avatar
mavrothal
Posts: 3096
Joined: Mon 24 Aug 2009, 18:23

#13 Post by mavrothal »

npierce wrote:
mavrothal wrote:I would like to change the JWM tray clock (minixcal) fonts . . .
First, to avoid confusion, understand that minixcal is not the JWM tray clock.
You are right.
Corrected the subject title.
Sorry for the confusion.
== [url=http://www.catb.org/esr/faqs/smart-questions.html]Here is how to solve your[/url] [url=https://www.chiark.greenend.org.uk/~sgtatham/bugs.html]Linux problems fast[/url] ==

npierce
Posts: 858
Joined: Tue 29 Dec 2009, 01:40

#14 Post by npierce »

No apology needed. Seeing an application name surrounded by <Clock> and </Clock>, it is an easy mistake to assume that the clock application is being defined.

Thanks for starting this thread. Now I have increased the size of my clock font, and my eyes are thanking me.

By the way, if anyone really would like to know how to change the font in minixcal (perhaps to make it less "mini" :) ), adding this to your personal gtkrc-2.0 file should do that:

Code: Select all

style "calendar_font" { font_name="Sans 24" }
widget "GtkWindow.GtkVBox.GtkCalendar" style "calendar_font"
What do I mean by "your personal gtkrc-2.0 file"?

Normally, that would be the /root/.gtkrc-2.0 file. But if you ever use the dictatorial :) theme changers included with some Puppies, you may find that the theme changer has claimed the file for its own use, and put up "no trespassing" signs, such as THEME AUTO-WRITTEN DO NOT EDIT.

In that case, you can still use that file, but be aware that if you ever use the theme changer again it will evict your changes.

You are better off using the file that the theme changer has dictated :) that you must use.

What file is that? Look in /root/.gtkrc-2.0 for a line like include "/root/.gtkrc.mine" or include "/root/.gtkrc-2.0.mine". That is the file you should use. It may not exist yet: create it.

(For more on .gtkrc-2.0 and theme changer utilities, see http://www.murga-linux.com/puppy/viewto ... 195#615195.)


One side-effect of adding those two lines is that any GTK+ application (not just minixcal) that happens to use a GtkCalendar widget inside of a GtkVBox widget inside of a top-level window will also use that font for its calendar. I don't happen to know of any such application, but just want to let folks know that that could happen.

Post Reply