So, I need to find the instances of a certain font and remove it....so far in my testing I am using the find command with regex to find a font I want to pull out. However, I seem to be slightly stuck, and I am sure the beard stroking Unix geniuses here can help me.
My example code:
This does in fact find Arial, but it doesn't find every class of Arial, like black narrow, etc. I cannot wrap my head around using the string Arial to pull out every instance of Arial....
Thanks in advance for any help. I am running tons and tons of Macs here, so everything is OS X.
I have some files in unix
ls -1
TMH.backend.tar.421E-03.Z
TMH.backend.tar.421E-04.Z
TMH.backend.tar.421E-05.Z
TMH.backend.tar.421E-06.Z
TMH.backend.tar.421E-07.Z
TMH.backend.tar.421E-08.Z
TMH.backend.tar.421E-08.Z.bak20081223164844
TMH.backend.tar.421E-09.Z... (1 Reply)
I'm trying to math all class references in a C++ file using grep with regular expression. I'm trying to know if a specific include is usuless or not, so I have to know if there is a refence in cpp.
I wrote this RE that searches for a reference from class ABCZ, but unfortunately it isn't working... (0 Replies)
Hi,
Does anyone know whether there is any console command available to get the info of the default Ubuntu OS or any config file where in I search for the font details?
I am using Ubuntu 8.04 and 10.04 (LTS) both together.
Thanks (1 Reply)
I am making an eBook.
I am editing the html in BBedit.
I need to replace all <p class="s5"> with just a <p>.
How do I write this for GREP?
Thank you,
Abby (5 Replies)
Hi all!
I am trying to register a device in an existing device class, but I am
having trouble getting the pointer to an existing class.
I can create a class in a module, get the pointer to it and then use
it to register the device with:
*cl = class_create(THIS_MODULE, className);... (0 Replies)
Hello All,
Wasn't sure if this was the correct thread to post this under but figured it has to do with Perl and Gtk2 so why not...
Anyway.. How can I find out what the Default font being used is inside a Gtk2::Widget. In this case I'm trying to figure out the
font being used inside a... (1 Reply)
I am having trouble running jgrasp. I get the message above when I try to run jgrasp. I am running fedora if that makes a difference.
I have already set my environmental variable with this. Hopefully I did it right.
JGRASP_HOME=/opt/jgrasp
export... (0 Replies)
I have the two class definition as follows.
class A { public: int a; };
class B : virtual public A{ };
The size of class A is shown as 4, and size of class B is shown as 16. Why is this effect ?. (2 Replies)
Hello All,
I am a learner in C++. I was testing my inheritance knowledge with following piece of code.
#include <iostream>
using namespace std;
class base
{
public :
void display()
{
cout << "In base display()" << endl;
}
void display(int k)
{... (2 Replies)
Anybody have an explanation for why \s doesn't match ' ' in a character class? Here are 3 examples with the final example showing that \s in a character class (demonstrated by using egrep -o) fails:
\s works outside of class..
# echo " FOO " | egrep -o '\s+\s'
FOO
Here is a... (6 Replies)
Discussion started by: blackrageous
6 Replies
LEARN ABOUT MOJAVE
tk_fontid
Tk_FontId(3) Tk Library Procedures Tk_FontId(3)__________________________________________________________________________________________________________________________________________________NAME
Tk_FontId, Tk_GetFontMetrics, Tk_PostscriptFontName - accessor functions for fonts
SYNOPSIS
#include <tk.h>
Font
Tk_FontId(tkfont)
Tk_GetFontMetrics(tkfont, fmPtr)
int
Tk_PostscriptFontName(tkfont, dsPtr)
ARGUMENTS
Tk_Font tkfont (in) Opaque font token being queried. Must have been returned by a previous call to Tk_GetFont.
Tk_FontMetrics *fmPtr (out) Pointer to structure in which the font metrics for tkfont will be stored. See DATA STRUCTURES below for
details.
Tcl_DString *dsPtr (out) Pointer to an initialized Tcl_DString to which the name of the Postscript font that corresponds to
tkfont will be appended.
_________________________________________________________________DESCRIPTION
Given a tkfont, Tk_FontId returns the token that should be selected into an XGCValues structure in order to construct a graphics context
that can be used to draw text in the specified font.
Tk_GetFontMetrics computes the ascent, descent, and linespace of the tkfont in pixels and stores those values in the structure pointer to
by fmPtr. These values can be used in computations such as to space multiple lines of text, to align the baselines of text in different
fonts, and to vertically align text in a given region. See the documentation for the font command for definitions of the terms ascent,
descent, and linespace, used in font metrics.
Tk_PostscriptFontName maps a tkfont to the corresponding Postscript font name that should be used when printing. The return value is the
size in points of the tkfont and the Postscript font name is appended to dsPtr. DsPtr must refer to an initialized Tcl_DString. Given a
"reasonable" Postscript printer, the following screen font families should print correctly:
Avant Garde, Arial, Bookman, Courier, Courier New, Geneva, Helvetica, Monaco, New Century Schoolbook, New York, Palatino, Symbol,
Times, Times New Roman, Zapf Chancery, and Zapf Dingbats.
Any other font families may not print correctly because the computed Postscript font name may be incorrect or not exist on the printer.
DATA STRUCTURES
The Tk_FontMetrics data structure is used by Tk_GetFontMetrics to return information about a font and is defined as follows:
typedef struct Tk_FontMetrics {
int ascent;
int descent;
int linespace;
} Tk_FontMetrics;
The ascent field is the amount in pixels that the tallest letter sticks up above the baseline, plus any extra blank space added by the
designer of the font.
The descent is the largest amount in pixels that any letter sticks below the baseline, plus any extra blank space added by the designer of
the font.
The linespace is the sum of the ascent and descent. How far apart two lines of text in the same font should be placed so that none of the
characters in one line overlap any of the characters in the other line.
SEE ALSO
font(n), MeasureChar(3)KEYWORDS
font, measurement, Postscript
Tk 8.0 Tk_FontId(3)