GnomeCanvasText properties (was: Re: The future of GdkFont declarations)



Hi,

I could cut&paste the GtkCellRendererText code blindly, but I would like
to understand the plan instead. So, could you help me?

The way I understand it, there are two ways to make multiple, partially
overlapping properties work:
	1, The last one always has precedence, e.g.
		Setting			Font size
		"font", "Sans 12"	12
		"size", 16		16
		"font", "Sans 12"	12
	   This is very easy to implement (obviously)
	2, The developer can tell explicitly which overriden values to
	   save, e.g.
		Setting			Font size
		"font", "Sans 12"	12
		"size", 16		16 (implicitly sets "store_size")
		"font", "Sans 12"	16
		"store_size", FALSE	16 (or maybe it should change to 
					    12 in this case???)
		"font", "Sans 12"	12

Looking at the GtkCellRendererText code, it looks like this is what's
happening there. However, I don't see why this couldn't be done by
getting/modifying/setting the current FontDescription -- OK I can imagine
very weird multi-thread cases where the actual FontDescription of the
canvas item could change after you get it but before you re-apply the
modified entry, but I think this is a case the app developer should care
about.

So, please enlighten me.

	Cactus

-- 
   .--= ULLA! =---------------------.   `We are not here to give users what
   \     http://cactus.rulez.org     \   they want'  -- RMS, at GUADEC 2001
    `---= cactus cactus rulez org =---'
8:20 Leviszi megsétáltatni pingvinjét. Ami persze a gonosz ingyenes Linux operációs rendszer jelképe.





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]