Click Here
home features news forums classifieds faqs links search
6071 members 
Amiga Q&A /  Free for All /  Emulation /  Gaming / (Latest Posts)
Login

Nickname

Password

Lost Password?

Don't have an account yet?
Register now!

Support Amigaworld.net
Your support is needed and is appreciated as Amigaworld.net is primarily dependent upon the support of its users.
Donate

Menu
Main sections
» Home
» Features
» News
» Forums
» Classifieds
» Links
» Downloads
Extras
» OS4 Zone
» IRC Network
» AmigaWorld Radio
» Newsfeed
» Top Members
» Amiga Dealers
Information
» About Us
» FAQs
» Advertise
» Polls
» Terms of Service
» Search

IRC Channel
Server: irc.amigaworld.net
Ports: 1024,5555, 6665-6669
SSL port: 6697
Channel: #Amigaworld
Channel Policy and Guidelines

Who's Online
15 crawler(s) on-line.
 126 guest(s) on-line.
 0 member(s) on-line.



You are an anonymous user.
Register Now!
 OlafS25:  19 mins ago
 Bruce72:  21 mins ago
 Rob:  52 mins ago
 MEGA_RJ_MICAL:  1 hr 8 mins ago
 t0lkien:  1 hr 14 mins ago
 amigakit:  1 hr 34 mins ago
 OneTimer1:  1 hr 47 mins ago
 Troels:  2 hrs 49 mins ago
 Gunnar:  3 hrs 4 mins ago
 zipper:  3 hrs 33 mins ago

/  Forum Index
   /  Amiga Development
      /  [E, MUI or general] Embossed font
Register To Post

PosterThread
r-tea 
[E, MUI or general] Embossed font
Posted on 28-Mar-2017 17:04:56
#1 ]
Regular Member
Joined: 21-Nov-2004
Posts: 315
From: Zdzieszowice, Poland

Is there a way to change a style of a font directly in the code - not in MUI preferences?
I need to insert an emboss-like short information text somewhere out of buttons or other gadgets.
I already did emboss tekst in buttons with MUI prefs.

This is what I need to do in code. I've read about italics, bold, colours in AmigaE docs, but there's nothing more. Maybe there are some MUI specific formatings hidden that I can use i E code?

Last edited by r-tea on 28-Mar-2017 at 05:06 PM.

_________________
I miss draggable screens in MorphOS... and do you? I know I'm in a minority unfortunately.

 Status: Offline
Profile     Report this post  
tboeckel 
Re: [E, MUI or general] Embossed font
Posted on 29-Mar-2017 7:07:06
#2 ]
Regular Member
Joined: 7-Oct-2004
Posts: 274
From: Rehmerloh, Germany

@r-tea

Most probably you want ghosted text. Use "\033g" as preparse string to activate ghosted text and "\033G" to disable it again. Essentially this is a simple shadow effect with swapped colors (light colored shadow, dark colored text).

I don't know whether this works with MUI 3.8 already, but at least with MUI 3.9 and all further versions.

_________________
Why stop it now, just when I am hating it?

Thore Böckelmann

 Status: Offline
Profile     Report this post  
r-tea 
Re: [E, MUI or general] Embossed font
Posted on 1-Apr-2017 18:40:36
#3 ]
Regular Member
Joined: 21-Nov-2004
Posts: 315
From: Zdzieszowice, Poland

@tboeckel

Thank you.
It looks a bit different, but actually this is what I expected.
Don't know why, but I had to use "\eg" instead of "\033g". Maybe it's because I use ECX compiler - nor EC.
Is somewhere out there a complete list of formatting codes like the one you have mentioned?

Last edited by r-tea on 01-Apr-2017 at 09:59 PM.

_________________
I miss draggable screens in MorphOS... and do you? I know I'm in a minority unfortunately.

 Status: Offline
Profile     Report this post  
r-tea 
Re: [E, MUI or general] Embossed font
Posted on 2-Apr-2017 11:27:35
#4 ]
Regular Member
Joined: 21-Nov-2004
Posts: 315
From: Zdzieszowice, Poland

@tboeckel

Oh, and is there a way to affect the font size inside the code?

_________________
I miss draggable screens in MorphOS... and do you? I know I'm in a minority unfortunately.

 Status: Offline
Profile     Report this post  
Hypex 
Re: [E, MUI or general] Embossed font
Posted on 2-Apr-2017 14:47:34
#5 ]
Elite Member
Joined: 6-May-2007
Posts: 11180
From: Greensborough, Australia

@r-tea

There is a list here from the mui.e module source. BTW the "\033" would be octal for 27 which is escape code in C. So with E/CX it just uses an "\e" which I think is more readable anyway. E for Escape.

/***************************************************************************
** Control codes for text strings
***************************************************************************/

#define MUIX_R '\er' /* right justified */
#define MUIX_C '\ec' /* centered */
#define MUIX_L '\el' /* left justified */

#define MUIX_N '\en' /* normal */
#define MUIX_B '\eb' /* bold */
#define MUIX_I '\ei' /* italic */
#define MUIX_U '\eu' /* underlined */

#define MUIX_PT '\e2' /* text pen */
#define MUIX_PH '\e8' /* highlight text pen */

Last edited by Hypex on 02-Apr-2017 at 02:54 PM.

 Status: Offline
Profile     Report this post  
r-tea 
Re: [E, MUI or general] Embossed font
Posted on 2-Apr-2017 16:40:45
#6 ]
Regular Member
Joined: 21-Nov-2004
Posts: 315
From: Zdzieszowice, Poland

@Hypex

Is it full list?
Can't see thr "g" code mentioned by tboeckel.

_________________
I miss draggable screens in MorphOS... and do you? I know I'm in a minority unfortunately.

 Status: Offline
Profile     Report this post  
tboeckel 
Re: [E, MUI or general] Embossed font
Posted on 2-Apr-2017 17:48:31
#7 ]
Regular Member
Joined: 7-Oct-2004
Posts: 274
From: Rehmerloh, Germany

@r-tea

Since a few day we also have an online version of all MUI Autodocs set up:
http://muidev.de/wiki/Documentation

The full list of available special sequences can be found in the MUI Autodocs of Text.mui in the description of MUIA_Text_Contents:
http://muidev.de/wiki/Documentation/API/MUI_Text#MUIA_Text_Contents

_________________
Why stop it now, just when I am hating it?

Thore Böckelmann

 Status: Offline
Profile     Report this post  
tboeckel 
Re: [E, MUI or general] Embossed font
Posted on 2-Apr-2017 17:55:13
#8 ]
Regular Member
Joined: 7-Oct-2004
Posts: 274
From: Rehmerloh, Germany

Quote:

Oh, and is there a way to affect the font size inside the code?


Set MUIA_Font to either one of the special values or to a TextFont pointer returned by OpenFont().

http://muidev.de/wiki/Documentation/API/MUI_Area#MUIA_Font

Keep in mind that it is a bad idea in general to enforce a specific font by setting a TextFont pointer from OpenFont(), as the user has no chance to modify this font via MUI prefs. You enforce a specific font with a specific size which does not necessarily match the other fonts the user has configured. So better stick with either the MUIV_Font_XXX values or leave the default settings active.

_________________
Why stop it now, just when I am hating it?

Thore Böckelmann

 Status: Offline
Profile     Report this post  
Hypex 
Re: [E, MUI or general] Embossed font
Posted on 3-Apr-2017 15:16:00
#9 ]
Elite Member
Joined: 6-May-2007
Posts: 11180
From: Greensborough, Australia

@r-tea

It is for the text escape strings. But it may be an old MUI 3.8 version module. It's from libraries/mui.m.

 Status: Offline
Profile     Report this post  
r-tea 
Re: [E, MUI or general] Embossed font
Posted on 5-Apr-2017 8:12:29
#10 ]
Regular Member
Joined: 21-Nov-2004
Posts: 315
From: Zdzieszowice, Poland

@tboeckel

Thanks. This documentation seems to be a bit newer than the one on MUI's home website.

I'll use MUIV_Font_xxx special values.

_________________
I miss draggable screens in MorphOS... and do you? I know I'm in a minority unfortunately.

 Status: Offline
Profile     Report this post  

[ home ][ about us ][ privacy ] [ forums ][ classifieds ] [ links ][ news archive ] [ link to us ][ user account ]
Copyright (C) 2000 - 2019 Amigaworld.net.
Amigaworld.net was originally founded by David Doyle