[KimDaBa] kimdaba rocks, html export, relaxng shema, mailing-list

Jesper K. Pedersen blackie at kde.org
Mon Jan 19 09:55:32 GMT 2004


Jean-Michel FAYARD <boulot.dodo at laposte.net> writes:

| > | 
| > | * about the ml
| > |     the website http://gmane.org provides a very useful 
| > |     NNTP <==> most mailing-lists of free-software projects <==> web interface
| > | [...]
| > rather not. I have so little time for KimDaBa, that I really do not want to
| > spent time on to many administrative things, sorry.
| Oh, I really understand. 
| If you agree, I can do this myself, and it won't bother you after that ;
| it will just be that the mailing-list could be reached with an alternative
| way.
I can see you did it already.
Thanks
I've made a link on the website.

| > | * Is kimdaba's database format documented anywhere ?
| > |     I was looking for a DTD, XML shema or something else
| > |     for a thing I will explain in a separate mail, but I 
| > |     was not able to find it.
| > | 
| > |     If not, I've created a RelaxNG shema (compact syntax),
| > |     mainly to see how the database looks like.
| > |     It's not (yet) a reference, just a thing good enough to
| > |     valid my current database.
| > Nope, but it is indeed pretty simple.
| > 
| It's not that it is a big deal to understand the format, but I want 
| to make the life easy for people writing similar apps to do some
| import/export with my data.
| I've browsed the source code to complete my initial shema ; 
| please accept this new version as the database documentation.
| 
| datatypes xsd = "http://www.w3.org/2001/XMLSchema-datatypes"
| 
| start  = 
|     element KimDaBa {  Config & kimdaba.Options & ConfigWindowSetup & Member-groups? & Images }
| 
| Config = 
|     element config  {  
| 	config.attlist,
| 	element SearchInfo {
| 	    attribute label { text },
| 	    attribute description { text },
| 	    element Options {
| 		attribute optionGroup { text}?,
| 		attribute value { text}?
| 	    }?
| 	}?
|     }
| kimdaba.Options	=
|     element options {
| 	element option {
| 	    attribute icon	{ text },
| 	    attribute name	{ text },
| 	    attribute text	{ text },
| 	    attribute show	{ xsd:boolean }?,
| 	    attribute type	{ xsd:integer }?,
Where did you get this from?
| 	    attribute size	{ xsd:integer }?,
Where did you get this from?

| 	    element value {
| 		attribute value { text }
| 	    } *
| 	}*
|     }
| 
| 

I don't know about the ConfigWindowSetup, I simply get that from KDockWindow
| ConfigWindowSetup = 
|     element configWindowSetup {
| 	Dock*, 
| 	SplitGroup*, 
| 	Widgets?, 
| 	Geometry?
|     }
| Dock =
|     element dock {
| 	element name	    { text },
| 	element hasParent   { text },
| 	element dragEnabled { text }
|     }
| SplitGroup = 
|     element splitGroup {
| 	element firstName	    { text }&
| 	element secondName	    { text }&
| 	element orientation	    { xsd:integer }&
| 	element separatorPos	    { xsd:integer }&
| 	element name		    { text }&
| 	element hasParent	    { xsd:boolean }&
| 	element dragEnabled	    { xsd:boolean }
|     }
| Widgets = 
|     element centralWidget   { text },
|     element mainDockWidget  { text }
| Geometry = 
|     element geometry {
| 	element x	{ xsd:integer },
| 	element y	{ xsd:integer },
| 	element width	{ xsd:integer },
| 	element height	{ xsd:integer }
|     }
| 
| 
| Member-groups = 
|     element member-groups   {
| 	element member {
| 	    attribute group-name    { text },
| 	    attribute option-group  { text },
| 	    attribute member	    { text }
| 	}*
|     }
| 
| Images	= 
|     element images {
| 	element image {
| 	    image.attlist   &
| 	    image.Options?  &	
| 	    Drawings?
| 	}*
|     }
| image.Options	=
|     element options {
| 	element option {
| 	    attribute name	{ text },
| 	    element value {
| 		attribute value { text }
| 	    } *
| 	}*
|     }
| Drawings = 
| 	element drawings {
| 	    element Line {
| 		figure.attlist
| 	    }* &
| 	    element Circle {
| 		figure.attlist
| 	    }* &
| 	    element Rectangle {
| 		figure.attlist
| 	    }*
| 	}
| figure.attlist = 
|     attribute _lastPos.x    { xsd:integer }?,
|     attribute _lastPos.y    { xsd:integer }?,
|     attribute _startPos.x   { xsd:integer }?,
|     attribute _startPos.y   { xsd:integer}?
Yiaks, did I really start the attrib with an underscore tsk tsk ;-)
| 
| image.attlist |=
|     attribute monthFrom	{ xsd:integer },
|     attribute dayFrom	{ xsd:integer },
|     attribute yearTo	{ xsd:integer },
|     attribute monthTo	{ xsd:integer },
|     attribute file	{ text },
|     attribute label	{ text },
|     attribute angle	{ xsd:boolean },
angle is an integer

|     attribute dayTo	{ xsd:integer },
|     attribute yearFrom	{ xsd:integer },
|     attribute description{text }
| 
| config.attlist |= 
|     attribute thumbSize		{ xsd:integer }?,
|     attribute trustTimeStamps	{ xsd:boolean }?,
|     attribute autoSave		{ xsd:integer }?,
|     attribute maxImages		{ xsd:integer }?,
|     attribute ensureImageWindowsOnScreen { xsd:boolean }?,
|     attribute htmlBaseDir	{ text }?,
|     attribute htmlBaseURL	{ text }?,
|     attribute infoBoxPosition	{ xsd:integer }?,
|     attribute showInfoBox	{ xsd:boolean }?,
|     attribute showDrawings	{ xsd:boolean }?,
|     attribute showDescription	{ xsd:boolean }?,
|     attribute showDate		{ xsd:boolean }?,
|     attribute locked		{ xsd:boolean }?,
|     attribute exclude		{ xsd:boolean }?, 
|     attribute passwd 		{text}?,
|     attribute imageDirectory	{ text }?
| config.attlist |=
|     attribute version		{ xsd:integer },   # TODO what version format ?
| # can have attribute like viewerWidth_%1 where %1 is the screen resolution or something like that.
yup, its the resolution. It makes it possible to specify different sizes
for your desktop machine and your laptop.

|     attribute viewerWidth_1024	{ xsd:integer }?,
|     attribute viewerWidth_1280	{ xsd:integer }?,
|     attribute viewerHeight_1024 { xsd:integer }?,
|     attribute viewerHeight_1280 { xsd:integer }?
These comes from the above.

I'm sorry, I'm really no XML expert and the xml files has been developed on
a need to have basis. So I can't guarantee that the above is correct.

Cheers
Jesper.



More information about the Kphotoalbum mailing list