Issues with setting some different font for UILabel - iphone

I would like to set the font size and familyname to the titleLabel. //Helvetica Neue UltraLight
[titleLabel setFont:[UIFont fontWithName:#"Helvetica Neue UltraLight" size:25.0f]];
This is not working.
Kindly tell me what could be wrong?
Any help will be appreciated?

the correct fontName is #"HelveticaNeue-UltraLight".
use something like this to get a nicely formatted list of available font names:
NSMutableString *str = [NSMutableString stringWithCapacity:1000];
for (NSString *familyName in [UIFont familyNames]) {
[str appendFormat:#"%#\n", familyName];
for (NSString *fontName in [UIFont fontNamesForFamilyName:familyName]) {
[str appendFormat:#" %#\n", fontName];
}
[str appendString:#"\n"];
}
NSLog(#"%#", str);
this is the current list for iOS5.1:
Thonburi
Thonburi-Bold
Thonburi
Snell Roundhand
SnellRoundhand-Bold
SnellRoundhand-Black
SnellRoundhand
Academy Engraved LET
AcademyEngravedLetPlain
Marker Felt
MarkerFelt-Wide
MarkerFelt-Thin
Geeza Pro
GeezaPro-Bold
GeezaPro
Arial Rounded MT Bold
ArialRoundedMTBold
Trebuchet MS
TrebuchetMS
TrebuchetMS-Bold
TrebuchetMS-Italic
Trebuchet-BoldItalic
Arial
Arial-BoldMT
ArialMT
Arial-ItalicMT
Arial-BoldItalicMT
Marion
Marion-Regular
Marion-Bold
Marion-Italic
Gurmukhi MN
GurmukhiMN
GurmukhiMN-Bold
Malayalam Sangam MN
MalayalamSangamMN-Bold
MalayalamSangamMN
Bradley Hand
BradleyHandITCTT-Bold
Kannada Sangam MN
KannadaSangamMN
KannadaSangamMN-Bold
Bodoni 72 Oldstyle
BodoniSvtyTwoOSITCTT-Book
BodoniSvtyTwoOSITCTT-Bold
BodoniSvtyTwoOSITCTT-BookIt
Cochin
Cochin
Cochin-BoldItalic
Cochin-Italic
Cochin-Bold
Sinhala Sangam MN
SinhalaSangamMN
SinhalaSangamMN-Bold
Hiragino Kaku Gothic ProN
HiraKakuProN-W6
HiraKakuProN-W3
Papyrus
Papyrus-Condensed
Papyrus
Verdana
Verdana
Verdana-Bold
Verdana-BoldItalic
Verdana-Italic
Zapf Dingbats
ZapfDingbatsITC
Courier
Courier-Bold
Courier
Courier-BoldOblique
Courier-Oblique
Hoefler Text
HoeflerText-Black
HoeflerText-Italic
HoeflerText-Regular
HoeflerText-BlackItalic
Euphemia UCAS
EuphemiaUCAS-Bold
EuphemiaUCAS
EuphemiaUCAS-Italic
Helvetica
Helvetica-LightOblique
Helvetica
Helvetica-Oblique
Helvetica-BoldOblique
Helvetica-Bold
Helvetica-Light
Hiragino Mincho ProN
HiraMinProN-W3
HiraMinProN-W6
Bodoni Ornaments
BodoniOrnamentsITCTT
Apple Color Emoji
AppleColorEmoji
Optima
Optima-ExtraBlack
Optima-Italic
Optima-Regular
Optima-BoldItalic
Optima-Bold
Gujarati Sangam MN
GujaratiSangamMN
GujaratiSangamMN-Bold
Devanagari Sangam MN
DevanagariSangamMN
DevanagariSangamMN-Bold
Times New Roman
TimesNewRomanPS-ItalicMT
TimesNewRomanPS-BoldMT
TimesNewRomanPSMT
TimesNewRomanPS-BoldItalicMT
Kailasa
Kailasa
Kailasa-Bold
Telugu Sangam MN
TeluguSangamMN-Bold
TeluguSangamMN
Heiti SC
STHeitiSC-Medium
STHeitiSC-Light
Apple SD Gothic Neo
AppleSDGothicNeo-Bold
AppleSDGothicNeo-Medium
Futura
Futura-Medium
Futura-CondensedExtraBold
Futura-CondensedMedium
Futura-MediumItalic
Bodoni 72
BodoniSvtyTwoITCTT-BookIta
BodoniSvtyTwoITCTT-Book
BodoniSvtyTwoITCTT-Bold
Baskerville
Baskerville-SemiBoldItalic
Baskerville-Bold
Baskerville-Italic
Baskerville-BoldItalic
Baskerville-SemiBold
Baskerville
Chalkboard SE
ChalkboardSE-Regular
ChalkboardSE-Bold
ChalkboardSE-Light
Heiti TC
STHeitiTC-Medium
STHeitiTC-Light
Copperplate
Copperplate
Copperplate-Light
Copperplate-Bold
Party LET
PartyLetPlain
American Typewriter
AmericanTypewriter-CondensedLight
AmericanTypewriter-Light
AmericanTypewriter-Bold
AmericanTypewriter
AmericanTypewriter-CondensedBold
AmericanTypewriter-Condensed
Bangla Sangam MN
BanglaSangamMN-Bold
BanglaSangamMN
Noteworthy
Noteworthy-Light
Noteworthy-Bold
Zapfino
Zapfino
Tamil Sangam MN
TamilSangamMN
TamilSangamMN-Bold
DB LCD Temp
DBLCDTempBlack
Arial Hebrew
ArialHebrew
ArialHebrew-Bold
Chalkduster
Chalkduster
Georgia
Georgia-Italic
Georgia-BoldItalic
Georgia-Bold
Georgia
Helvetica Neue
HelveticaNeue-Bold
HelveticaNeue-CondensedBlack
HelveticaNeue-Medium
HelveticaNeue
HelveticaNeue-Light
HelveticaNeue-CondensedBold
HelveticaNeue-LightItalic
HelveticaNeue-UltraLightItalic
HelveticaNeue-UltraLight
HelveticaNeue-BoldItalic
HelveticaNeue-Italic
Gill Sans
GillSans-LightItalic
GillSans-BoldItalic
GillSans-Italic
GillSans
GillSans-Bold
GillSans-Light
Palatino
Palatino-Roman
Palatino-Bold
Palatino-BoldItalic
Palatino-Italic
Courier New
CourierNewPSMT
CourierNewPS-BoldMT
CourierNewPS-BoldItalicMT
CourierNewPS-ItalicMT
Oriya Sangam MN
OriyaSangamMN-Bold
OriyaSangamMN
Didot
Didot-Italic
Didot
Didot-Bold
Bodoni 72 Smallcaps
BodoniSvtyTwoSCITCTT-Book

You use wrong font name, correct one will be:
[titleLabel setFont:[UIFont fontWithName:#"HelveticaNeue-UltraLight" size:25.0f]];
You can see the list of all available font names for a given font family using +fontNamesForFamilyName: method in UIFont, e.g.:
[UIFont fontNamesForFamilyName:#"Helvetica Neue"]
Edit: Also mind that some fonts may not be present on all versions of iOS as Apple gradually adds (and sometimes probably removes) fonts from standard OS set.
It appears that "HelveticaNeue-UltraLight" font present in OS starting 5.0 version. If you want to use it in older OS versions you'll need to embed it to you application - check for example this answer for details how to do that

Please see List of Fonts available in iOS
and use font names according this...

Related

tFPDF unicode characters in Arial bold

I'm trying to create PDF by FPDF (tFPDF) but I still can't create output with correct charset.
Problem is in czech letters: ě,š,č,ř,ž,ů etc...
Source:
<?php
require_once('../tfpdf/tfpdf.php');
define("_SYSTEM_TTFONTS", "C:/Windows/Fonts/");
$pdf = new tFPDF('P','mm','A5');
$pdf->SetMargins(8,5,8);
$pdf->AddPage();
// Pracoviště
$pdf->SetFont('Arial', '', 10);
$pdf->Cell(25,12,'Pracoviště:','L',0);
$pdf->Output();
?>
I need to write "Pracoviště:" but output is "PracoviÅ¡tÄ›:".
For regular Arial I solved it by:
$pdf->AddFont('Arial','','arial.ttf',true);
but it doesen't work for bold.
I tried:
$pdf->AddFont('Arial','','arial.ttf',true); // Arial
$pdf->AddFont('Arial','B','arialbd.ttf',true); // Arial Bold
$pdf->SetFont('Arial', '', 10);
$pdf->Cell(25,12,'Pracoviště:'); // output: Pracoviště:
$pdf->SetFont('Arial', 'B', 10);
$pdf->Cell(25,12,'Pracoviště:'); // output: PracoviÅ¡tÄ›:
Interestingly if I use Arial Black file, it works, but it's not font what I need.
$pdf->AddFont('Arial','','arial.ttf',true); // Arial
$pdf->AddFont('Arial','B','ariblk.ttf',true); // Arial Black
$pdf->SetFont('Arial', '', 10);
$pdf->Cell(25,12,'Pracoviště:'); // output: Pracoviště:
$pdf->SetFont('Arial', 'B', 10);
$pdf->Cell(25,12,'Pracoviště:'); // output: Pracoviště: - but Arial Black font, I need Arial Bold
Why Arial works, Arial Black works too and Arial Bold doesn't work? How to solve it?

Loading fonts in Python/Pillow on a Mac

The Pillow ImageFont documentation has a few examples of using different fonts, but they don't work "out of the box" on a Mac. It's probably not too hard to figure out where my system fonts are located, but I'm lazy and would like a simple example that I can just edit.
So: how can I use Pillow on a Mac to write some text in a different font and size from the default?
Ok, "Lazy One" ;-) Here is an example:
from PIL import Image, ImageFont, ImageDraw
# Make a red canvas and get a drawing context to it
img = Image.new(mode='RGB', size=(500, 200), color=(255,0,0))
draw = ImageDraw.Draw(img)
# Get a "Chalkduster" TTF
chalk = ImageFont.truetype("Chalkduster.ttf",16)
# Get a "Keyboard" TTF
kbd = ImageFont.truetype("Keyboard.ttf",26)
# Make example for Lazy One - showing how to colour cyan too
draw.text((40,40),"Keyboard",font=kbd, fill=(0,255,255))
# And another
draw.text((20,140),"Chalkduster",font=chalk)
img.save("test.png")
If you want a list of all the TTF fonts on your system, you can look in both:
/System/Library/Fonts, and
/Library/Fonts
And, if you are very lazy, you can check in both at the same time from Terminal:
find {/System,}/Library/Fonts -name \*ttf
Sample Output
/System/Library/Fonts/SFNSDisplay.ttf
/System/Library/Fonts/Symbol.ttf
/System/Library/Fonts/ZapfDingbats.ttf
/System/Library/Fonts/Apple Braille.ttf
/System/Library/Fonts/SFNSText.ttf
/System/Library/Fonts/Apple Braille Outline 6 Dot.ttf
/System/Library/Fonts/Apple Braille Pinpoint 6 Dot.ttf
/System/Library/Fonts/Apple Symbols.ttf
/System/Library/Fonts/SFNSTextItalic.ttf
/System/Library/Fonts/SFNSRounded.ttf
/System/Library/Fonts/Apple Braille Pinpoint 8 Dot.ttf
/System/Library/Fonts/Keyboard.ttf
/System/Library/Fonts/Apple Braille Outline 8 Dot.ttf
/Library/Fonts/Webdings.ttf
/Library/Fonts/Zapfino.ttf
/Library/Fonts/Trebuchet MS Italic.ttf
/Library/Fonts/Georgia.ttf
/Library/Fonts/Verdana Bold.ttf
/Library/Fonts/Bodoni 72 Smallcaps Book.ttf
/Library/Fonts/Times New Roman Bold Italic.ttf
/Library/Fonts/Silom.ttf
/Library/Fonts/Verdana Italic.ttf
/Library/Fonts/Times New Roman Italic.ttf
/Library/Fonts/Bradley Hand Bold.ttf
/Library/Fonts/Arial Narrow Italic.ttf
/Library/Fonts/AppleGothic.ttf
/Library/Fonts/DIN Condensed Bold.ttf
/Library/Fonts/Farisi.ttf
/Library/Fonts/Arial Bold.ttf
/Library/Fonts/Trebuchet MS.ttf
/Library/Fonts/Mishafi.ttf
/Library/Fonts/Trattatello.ttf
/Library/Fonts/BigCaslon.ttf
/Library/Fonts/Courier New Bold.ttf
/Library/Fonts/NISC18030.ttf
/Library/Fonts/Lao Sangam MN.ttf
/Library/Fonts/Luminari.ttf
/Library/Fonts/Times New Roman.ttf
/Library/Fonts/Brush Script.ttf
/Library/Fonts/Georgia Italic.ttf
/Library/Fonts/Courier New Italic.ttf
/Library/Fonts/Arial Unicode.ttf
/Library/Fonts/Chalkduster.ttf
/Library/Fonts/Apple Chancery.ttf
/Library/Fonts/AppleMyungjo.ttf
/Library/Fonts/Arial Narrow Bold Italic.ttf
/Library/Fonts/Arial Narrow.ttf
/Library/Fonts/Courier New.ttf
/Library/Fonts/Wingdings 3.ttf
/Library/Fonts/Wingdings 2.ttf
/Library/Fonts/Hoefler Text Ornaments.ttf
/Library/Fonts/Bodoni Ornaments.ttf
/Library/Fonts/Skia.ttf
/Library/Fonts/Trebuchet MS Bold Italic.ttf
/Library/Fonts/Impact.ttf
/Library/Fonts/Kokonor.ttf
/Library/Fonts/Tahoma Bold.ttf
/Library/Fonts/Arial.ttf
/Library/Fonts/Diwan Thuluth.ttf
/Library/Fonts/Ayuthaya.ttf
/Library/Fonts/Khmer Sangam MN.ttf
/Library/Fonts/Trebuchet MS Bold.ttf
/Library/Fonts/Arial Black.ttf
/Library/Fonts/Courier New Bold Italic.ttf
/Library/Fonts/Comic Sans MS.ttf
/Library/Fonts/DIN Alternate Bold.ttf
/Library/Fonts/Wingdings.ttf
/Library/Fonts/Sathu.ttf
/Library/Fonts/Arial Bold Italic.ttf
/Library/Fonts/Tahoma.ttf
/Library/Fonts/PlantagenetCherokee.ttf
/Library/Fonts/Georgia Bold.ttf
/Library/Fonts/Verdana Bold Italic.ttf
/Library/Fonts/Microsoft Sans Serif.ttf
/Library/Fonts/Georgia Bold Italic.ttf
/Library/Fonts/Arial Rounded Bold.ttf
/Library/Fonts/Times New Roman Bold.ttf
/Library/Fonts/Krungthep.ttf
/Library/Fonts/Gurmukhi.ttf
/Library/Fonts/Andale Mono.ttf
/Library/Fonts/Mishafi Gold.ttf
/Library/Fonts/Herculanum.ttf
/Library/Fonts/Comic Sans MS Bold.ttf
/Library/Fonts/Arial Italic.ttf
/Library/Fonts/Verdana.ttf
/Library/Fonts/Arial Narrow Bold.ttf

Cocoa NSButton with underlined title

I'm trying to create a NSButton with an underlined title.
#IBOutlet var myButton: NSButton!
let underlineAttribute = [NSAttributedString.Key.underlineStyle: NSUnderlineStyle.single]
let underlineAttributedString = NSAttributedString(string: "Button Title", attributes: underlineAttribute)
myButton.attributedTitle = underlineAttributedString
But I get the error:
<NSATSTypesetter: 0x600003719500>: Exception -[__SwiftValue _getValue:forType:]: unrecognized selector sent to instance 0x600000ca4060 raised during typesetting layout manager <NSLayoutManager: 0x100e1a140>
1 containers, text backing has 5 characters
selected character range {0, 0} affinity: upstream granularity: character
marked character range {0, 0}
Currently holding 5 glyphs.
Glyph tree contents: 5 characters, 5 glyphs, 1 nodes, 64 node bytes, 256 storage bytes, 320 total bytes, 64.00 bytes per character, 64.00 bytes per glyph
Layout tree contents: 5 characters, 5 glyphs, 0 laid glyphs, 0 laid line fragments, 1 nodes, 64 node bytes, 0 storage bytes, 64 total bytes, 12.80 bytes per character, 12.80 bytes per glyph, 0.00 laid glyphs per laid line fragment, 0.00 bytes per laid line fragment
, glyph range {0 5}. Ignoring...
Is it possible to create an underlined title in general?
Thanks!
Looks like you figured it out, but for documentation purposes: NSUnderlineStyle.single -> NSUnderlineStyle.single.rawValue
#IBOutlet var myButton: NSButton!
let underlineAttribute = [NSAttributedString.Key.underlineStyle: NSUnderlineStyle.single.rawValue]
let underlineAttributedString = NSAttributedString(string: "Button Title", attributes: underlineAttribute)
myButton.attributedTitle = underlineAttributedString

PdfReaderContentParser.ProcessContent returns whitespace for clear text

I'd like to parse a pdf for texts containing both, binary and clear text data. When I try to do it with PdfReaderContentParser the GetResultantText method returns the right texts for the binary content but whitespaces for the clear text content. Here is the code I use:
byte[] binaryPdf = File.ReadAllBytes(this.fileName);
reader = new PdfReader(binaryPdf);
PdfReaderContentParser parser = new PdfReaderContentParser(reader);
for (int i = 1; i <= reader.NumberOfPages; i++)
{
SimpleTextExtractionStrategy simpleStragety = parser.ProcessContent(i, new SimpleTextExtractionStrategy());
string contentText = simpleStragety.GetResultantText();
// Do something with the contentText
// ...
}
Any idea how to get all content?
Overview
In a comment the OP clarified which texts he was missing in his extracted text:
Basically for all descriptions on the left-hand side (e.g. Lifting moment) I get whitespaces instead of the actual text.
The reason for this is fairly simple: In the page content there are only spaces (if anything at all) on most of the left side. The labels you see actually are read-only form fields.
For example the "Lifting moment" is the value of the form field 13B141032.
If you want text extraction to include these fields, too, you should consider flattening the document in a first step (moving the field appearances into the regular page content stream) and extracting text from this flattened document.
Document analysis
It looks like the major part of the internationalization of the specification labels has been done using form fields.
For an overview I separated the original document
into its regular page content
and the form fields
There indeed are several strings of spaces in the page content under the form fields.
I would assume that there once was an earlier version of that document (or a template for it) which contained those labels (maybe in only one language or probably two) as page content.
Then there was a task of more dynamic internationalization, so someone replaced the existing labels in the page content by spaces and added new internationalized labels as read-only form-fields, probably because form fields are easier to manipulate.
Considering that the original labels seem to have been replaced by an equal number of spaces, though, one might speculate that there even is another program manipulating the page stream of this and similar documents at hard coded offsets, and to not break this program in the course of internationalization the actual labels had to be created outside the page content. Stranger things have happened...
Flatten and extract
As mentioned above, if you want text extraction to include these fields, too, you should consider flattening the document in a first step (moving the field appearances into the regular page content stream) and extracting text from this flattened document. This can be done like this:
[Test]
public void ExtractFlattenedTextTestSeeb()
{
FileInfo file = new FileInfo(#"PATH_TO_FILE\41851208.pdf");
Console.Out.Write("41851208.pdf, flattened before extraction\n\n");
using (MemoryStream memStream = new MemoryStream())
{
using (PdfReader readerOrig = new PdfReader(file.FullName))
using (PdfStamper stamper = new PdfStamper(readerOrig, memStream))
{
stamper.Writer.CloseStream = false;
stamper.FormFlattening = true;
}
memStream.Position = 0;
using (PdfReader readerFlat = new PdfReader(memStream))
{
PdfReaderContentParser parser = new PdfReaderContentParser(readerFlat);
for (int i = 1; i <= readerFlat.NumberOfPages; i++)
{
SimpleTextExtractionStrategy simpleStragety = parser.ProcessContent(i, new SimpleTextExtractionStrategy());
string contentText = simpleStragety.GetResultantText();
Console.Write("Page {0}:\n\n{1}\n\n", i, contentText);
}
}
}
}
The result StandardOutput:
41851208.pdf, flattened before extraction
Page 1:
90–120 l/min
(23.8–31.7 US gal./min)
60 kg
(132 lbs)
115 kg
(254 lbs)
350 l
(92.5 US gal.)
100 kg 105 kg
(220 lbs) (231 kg)
100 kg
(220 lbs)
250 l 300 l
(66.0 US gal.) (79.3 US gal.)
90 kg
(198 lbs)
180 l
(47.6 US gal.)
5305kg
(11695 lbs)
5265kg
(11607 lbs)
5395kg
(11894 lbs)
5205kg
(11475 lbs)
5010kg
(11045 lbs)
4780kg
(10538 lbs)
4470kg
(9854 lbs)
4190kg
(9237 lbs)
3930kg
(8664 lbs)
5215kg
(11497 lbs)
5045kg
(11122 lbs)
4860kg
(10714 lbs)
4650kg
(10251 lbs)
4350kg
(9590 lbs)
4100kg
(9039 lbs)
3850kg
(8488 lbs)
25.2 m
(82’ 8")
23.2 m
(76’ 1")
21.0 m
(68’ 11")
18.7 m
(61’ 4")
16.4 m
(53’ 10")
14.1 m
(46’ 3")
11.8 m
(38’ 9")
9.7 m
(31’ 10")
7.7 m
(25’ 3")
36.5 MPa (365 bar)
(5293 psi)
endlos
endless
sans finite
25.2 m
31.2 m
(82’ 8")
(102’ 4")
21.0 m
(68’ 11")
14900kg
(32848 lbs)
403.2 kNm (41.1 mt)
(297270 ft.lbs)
49.1 kNm (5.0 mt)
PK 42002–SH A–G
(36210 ft.lbs)
37.3 kNm (3.8 mt)
PK 42002–SH A–C
(27510 ft.lbs)
1GETR 2GETR
PK 42002–SH A – C
KT250 KT300 KT350 KT180
2GETR STZY
+V1
+V2
+2/4
7(F) 8(G) 6(E) 5(D) 4(C) 3(B) 2(A)
+V1
+V2
(S410–SK–D)
DTS410SHC/03
0100
11/2010
PK 42002–SH
Type Model Modell
Page Page Seite
Chapitre Chapter Kapitel
Edition Edition Ausgabe
Öltank
Mehrgewicht:
Alle Gewichtsangaben ohne Aufbauzubehör,Zusatzgeräte und Öl.
Hydr. Ausschübe:
Max. Reichweite + Fly-Jib:
Max. Reichweite:
Fördermenge der Pumpe:
Betriebsdruck:
Schwenkmoment:
Schwenkbereich:
Max. Reichweite:
Max. hydraulische Reichweite:
Max. Hubkraft:
Max. Hubmoment:
Gewicht +V ohne 2/4
Krangewicht (R3X,STZS):
Technische Daten
Konstruktionsänderungen vorbehalten, fertigungstechn. Toleranzen müssen berücksichtigt werden.
Oil tank
Excess weight:
All weights given without assembly accessory,additional devices and oil.
Hydr. boom extensions:
Max. outreach + Fly-Jib:
Max. outreach:
Pump capacity:
Operating pressure:
Slewing torque:
Slewing angle:
Max. outreach:
Max. hydraulic outreach:
Max. lifting capacity:
Lifting moment:
Weight +V without 2/4
Crane weight (R3X,STZS):
Specifications
Subject to change, production tolerances have to be taken into account.
Réservoir
Excessif poids:
Tous les poids sans huile ni accessoire de montage ni appareils accessoires
Extensions hydrauliques:
Portee maximale + Fly-Jib:
Max. portee:
Debit de pompe:
Pression d' utilisation:
Couple de rotation:
Angle de rotation:
Max. portee:
Portee hydraulique maximale:
Capacite maxi de levage:
Couple de levage:
Poids +V sans 2/4
Poids grue (R3X,STZS):
Données Techniques
Sous reserve de modifications de conception. Les tolerances relatives a la technique de production doivent etre prises en consideration.
As you see, "Lifting moment" and all the other missing labels are there now.

What's the font family of the page title on MobileSafari?

The webpage title on MobileSafari looks carven,host to make this effect?And what's the font family and font size of the title?
Thank you very much!
Open any iOS project in Xcode.
Launch MobileSafari in the simulator and visit google.
In Xcode, choose Product > Attach to Process > MobileSafari.
Choose Product > Debug > Pause.
In the debug console, type po [[UIApp keyWindow] recursiveDescription].
Note that this only works on the simulator. On the device, you can only attach to apps that you have installed using Xcode.
Doing all that gives you a printout of Mobile Safari's view hierarchy. Searching through it, I find this UILabel:
| | | | | <UILabel: 0x1096e800; frame = (0 0; 308 16); text = 'Google'; clipsToBounds = YES; userInteractionEnabled = NO; layer = <CALayer: 0x1096e8c0>>
The address of the UILabel object will be different each time we do this.
Anyway, we can print that label's font like this:
(lldb) po [0x1096e800 font]
$2 = 0x0bb88110 <UICFFont: 0xbb88110> font-family: ".Helvetica NeueUI"; font-weight: bold; font-style: normal; font-size: 13px
We can print its text color:
(lldb) po [0x1096e800 textColor]
$13 = 0x1096eb50 UIDeviceRGBColorSpace 0.173 0.212 0.259 0.9
We can also print its shadow color:
(lldb) po [0x1096e800 shadowColor]
$4 = 0x1096eb70 UIDeviceWhiteColorSpace 1 0.43
Printing the shadow offset is harder, because it is a CGSize structure, not a built-in type. The debugger doesn't know about CGSize because MobileSafari doesn't include debug information. We have to give the debugger a definition. This hideous command works:
(lldb) expr -o -- typedef struct { float x; float y; } CGSize; (id)[NSValue valueWithCGSize:(CGSize)[(id)0x1096e800 shadowOffset]]
$11 = 0x08063e60 NSSize: {0, 1}
It's the system's default font, Helvetica-Neue. In UIKit, you'd get it with [UIFont systemFontOfSize:...] or [UIFont boldSystemFontOfSize:...]. The "carve" effect is a simple white drop shadow. It's achieved with the shadowColor and shadowOffset properties of UILabel.