mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-01 18:51:55 +00:00
Implement Font comparisions.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@6505 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
7f477044d1
commit
fa380dcc80
6 changed files with 5893 additions and 0 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2000-04-24 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
|
* Source/NSFont.m (-isEqual:): Implement.
|
||||||
|
(hash): Likewise.
|
||||||
|
|
||||||
|
* Documentation/gsdoc/DPSOperators.gsdoc: New file.
|
||||||
|
|
||||||
2000-04-24 Fred Kiefer <FredKiefer@gmx.de>
|
2000-04-24 Fred Kiefer <FredKiefer@gmx.de>
|
||||||
|
|
||||||
* Parser/*: Updated the parser to support more of the RTF
|
* Parser/*: Updated the parser to support more of the RTF
|
||||||
|
|
3529
Documentation/gsdoc/DPSOperators.gsdoc
Normal file
3529
Documentation/gsdoc/DPSOperators.gsdoc
Normal file
File diff suppressed because it is too large
Load diff
2317
Documentation/gsdoc/DPSOperators.html
Normal file
2317
Documentation/gsdoc/DPSOperators.html
Normal file
File diff suppressed because it is too large
Load diff
|
@ -126,6 +126,13 @@
|
||||||
<item><uref url="NSWindowController.html">NSWindowController</uref></item>
|
<item><uref url="NSWindowController.html">NSWindowController</uref></item>
|
||||||
<item><uref url="NSWorkspace.html">NSWorkspace</uref></item>
|
<item><uref url="NSWorkspace.html">NSWorkspace</uref></item>
|
||||||
</list>
|
</list>
|
||||||
|
<p>
|
||||||
|
There is also documentation on various GUI functions.
|
||||||
|
</p>
|
||||||
|
<list>
|
||||||
|
<item><uref url="DPSOperators.html">DPSOperators</uref></item>
|
||||||
|
</list>
|
||||||
|
|
||||||
</chapter>
|
</chapter>
|
||||||
</body>
|
</body>
|
||||||
</gsdoc>
|
</gsdoc>
|
||||||
|
|
|
@ -126,6 +126,13 @@
|
||||||
<li><a href="NSWindowController.html">NSWindowController</a>
|
<li><a href="NSWindowController.html">NSWindowController</a>
|
||||||
<li><a href="NSWorkspace.html">NSWorkspace</a>
|
<li><a href="NSWorkspace.html">NSWorkspace</a>
|
||||||
</ul>
|
</ul>
|
||||||
|
<p>
|
||||||
|
|
||||||
|
There is also documentation on various GUI functions.
|
||||||
|
</p>
|
||||||
|
<ul>
|
||||||
|
<li><a href="DPSOperators.html">DPSOperators</a>
|
||||||
|
</ul>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -200,6 +200,32 @@ void setNSFont(NSString* key, NSFont* font)
|
||||||
[super dealloc];
|
[super dealloc];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (BOOL) isEqual: (id)anObject
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
float *obj_matrix;
|
||||||
|
if (anObject == self)
|
||||||
|
return YES;
|
||||||
|
if ([anObject isKindOfClass: self->isa] == NO)
|
||||||
|
return NO;
|
||||||
|
if ([[anObject fontName] isEqual: fontName] == NO)
|
||||||
|
return NO;
|
||||||
|
obj_matrix = [anObject matrix];
|
||||||
|
for (i = 0; i < 6; i++)
|
||||||
|
if (obj_matrix[i] != matrix[i])
|
||||||
|
return NO;
|
||||||
|
return YES;
|
||||||
|
}
|
||||||
|
|
||||||
|
- (unsigned) hash
|
||||||
|
{
|
||||||
|
int i, sum;
|
||||||
|
sum = 0;
|
||||||
|
for (i = 0; i < 6; i++)
|
||||||
|
sum += matrix[i] * ((i+1) * 17);
|
||||||
|
return ([fontName hash] + sum);
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Private method for NSFontManager
|
// Private method for NSFontManager
|
||||||
//
|
//
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue