User:Ramtin

Real name : Ramtin Khoshniat

Country : Belgium

City : Familleureux

School : ECOLE INDUSTRIELLE ET COMMERCIALE D'ECAUSSINNES

- 16-11-2010
i have installed microsoft visual c++ 2008

cygwin version 1.7.7.1

Windows SDK for Windows Server 2008 and .NET Framework 3.5

i am using windows 7 (x86) as operation system.

i have downloaded code source and copied all files gpc,unicows.dll,... to external folder in the source code

and i have created awk.exe and gunzip by coping gawk.exe and unzip.exe to gunzip.exe

Then later i started the configuration, but i encountered a little problem, which resulted due to the fact that 2 files had the same name (awk and awk.exe). The problem was solved by removing the file names awk

Then i started the configuration. Here is the command that i used for the configuration

./configure --with-OOo4Kids --disable-binfilter --with-lang=fr --disable-odk --disable-mozilla --enable-directx --disable-activex --disable-atl --with-java=no --with-cl-home="/cygdrive/c/Program Files/Microsoft Visual Studio 9.0/VC" --with-use-shell=bash --disable-binfilter --with-frame-home="/cygdrive/c/Program Files/Microsoft SDKs/Windows/v6.1" --with-psdk-home="/cygdrive/c/Program Files/Microsoft SDKs/Windows/v6.1" --with-midl-path="/cygdrive/c/Program Files/Microsoft SDKs/Windows/v6.1/Bin/" --with-asm-home="/cygdrive/c/Program Files/Microsoft Visual Studio 9.0/VC" --with-csc-path="/cygdrive/c/WINDOWS/Microsoft.NET/Framework/v3.5"

then i started the build. during build The following error occurred : .it's an error related to TransEx 3.1 i haven't found any solution yet(seaching for a solution)

In the log, you read :

ERROR: Error 65280 occurred while making /cygdrive/e/ooo4kids/svtools/source/items1

This means the error stands in svtools. To start solving this breakage, do :

cd svtools rm -rf wntmsci12.pro build

Then paste the log once you hit the breakage again. Thanks

Eric Bachard 07:47, 16 November 2010 (UTC)

- 17-11-2010
build progress:

today during build i had some errors, the following is an illustration of the error   and

this same error was commonly bound to other files too (xhp extension)

The problems has been resolved by ericb(thanks for his help). It was related to some corrupted (xhp extension) files in the source

(OOo4Kids\helpcontent2\source\text)

- 21-11-2010
After having a lot of issues with compiling the source code under the windows operating system,

i have decided to install linux(Distribution Ubuntu 10.10) on another pc and continue working on it. After installation of linux and and download of source code, i have i finished compilation of

the source code with a

single problem.

configuration that i used in linux:

./configure --disable-binfilter --disable-odk --with-lang="ar de es fi fr it nb nl pl zh-CN zh-TW" \ --disable-vba --disable-mozilla --with-system-python --with-system-libxml --enable-cups --disable-fontconfig \ --disable-gnome-vfs --with-use-shell=bash --with-java=no --with-OOo4Kids --disable-gtk --enable-presenter-extra-ui

compilation took me 2 hours build (--all -P6 -- -P6 -- -P6 -- -P6) and took up approximately 14 gb of the hard drive

it has been completed successfully

- 23-11-2010
I have placed no_binfilter.diff (patch -p0 < no_binfilter.diff) in $scr_rootm, then i removed the --disable-binfilter

line from configuration, and finally after running the compilation, it has been completed without any error

- Task
participate in improving the user interface and user experience

Creation of three entry menus who's job is to change user level and will adapt level toolbar to

the users choice. There are three user levels, namely - Beginner, Average and Expert.

- 17-12-2010
Meeting IRC

- Define new slot for USERLEVEL
ShowUserLevel : The name in the middle of each first line of a block was used as the name of the property or method in the Basic API and today this name is the internal command name that is matched to any ".uno:xxx" CommandURLs of the Dispatch API.

SID_ CHANGEUSERLEVEL : The last part of each first line is the so called SlotID.

Added:

 SfxVoidItem ChangeUserLevel SID_CHANGEUSERLEVEL [	/* flags: */ AutoUpdate = FALSE, Cachable = Cachable, FastCall = FALSE, HasCoreId = FALSE, HasDialog = TRUE, ReadOnlyDoc = TRUE, Toggle = FALSE, Container = FALSE, RecordAbsolute = FALSE, RecordPerSet; Synchron; /* config: */ AccelConfig = TRUE, MenuConfig = TRUE, StatusBarConfig = FALSE, ToolBoxConfig = TRUE, GroupId = GID_APPLICATION; ] 

- define content for the USERLEVEL dialog box
Added : in sfx2/inc/sfx2/sfx.hrc


 * 1) define RID_CHANGEUSERLEVEL                   (RID_SFX_START+40)
 * 2) define MENU_SETUSERLEVEL_BEGINNER                     11
 * 3) define MENU_SETUSERLEVEL_AVERAGE             	 12
 * 4) define MENU_SETUSERLEVEL_EXPERT                	 13

- Add constante SID_CHANGEUSERLEVEL
added : in sfx2/inc/sfx2/sfxsids.hrc

#define SID_ CHANGEUSERLEVEL                        (SID_SFX_START + 305)

- generate an ".UNO" command
added : in in svx/inc/globlmn_tmpl.hrc.

#define ITEM_HELP_USERLEVEL \ Identifier = SID_CHANGEUSERLEVEL ; \ Command = ".uno:ChangeUserLevel" ; \ HelpID = SID_ CHANGEUSERLEVEL ; \ Text [ en-US ] = "Level" ; \ Text [ fr ] = "Niveau" ; \

- 30-12-2010
Meeting IRC

- 03-01-2011
define the interface

i have added MiscExec_Impl method in sfx2/sdi/appslots.sdi  .MiscExec_Impl is a method from class SfxAplication

method MiscExec :for display of the dialog box.

SID_ CHANGEUSERLEVEL [                                                                                                                        ExecMethod = MiscExec_Impl ; ] SfxApplication::MiscExec_Impl( SfxRequest& rReq ) void Class::ExecMethod( SfxRequest& ); the SfxRequest contains everything necessary for the execution of a slot.

in sfx2/source/appl/appserv.cxx and i have created a new case in SfxApplication called case SID_ CHANGEUSERLEVEL.

- 06-01-2011
Meeting IRC

- 07-01-2011
Search a solution for the project with Dwalfear

Suggestion : Here

- 13-01-2011
Meeting IRC

- 14-01-2011
me and Dwalfear we have tried to find a solution here is the link the solution, it is not yet complete.

link : Here.

16-01-2011
studying c++ and toolbar code ,

trying to complete the solution.

- 19-01-2011
some modification in code link --> Here

version .diff downloadable link --> Here

- 27-01-2011
IRC MEETING

creation menu ITEM_CHANGEUSERLEVEL_MENU with 3 submenus for each level beginner,avrage,expert in index: svx/inc/globlmn_tmpl.hrc

and nodes in index: officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu

- 30-01-2011
ITEM_CHANGEUSERLEVEL_MENU with 3 submenu and 3

and 3 separated Level

the user will have the possibility to add either a new change user level which contain 3 submenu beginner,avrage,expert

or add level directly i mean add for example beginner etc

Index: svx/inc/globlmn_tmpl.hrc =================================================================== --- svx/inc/globlmn_tmpl.hrc	(révision 1140) +++ svx/inc/globlmn_tmpl.hrc	(copie de travail) @@ -33,6 +33,57 @@ /* Beschreibung: Menu-IDs */ + + +    +      #define ITEM_CHANGEUSERLEVEL_BEGINNER \ +   Identifier = SID_CHANGUSERLEVEL_BEGINNER ; \ +	Command = ".uno:SetUserLevelBeginner" ; \ +   HelpID = SID_CHANGUSERLEVEL_BEGINNER ; \ +   Text [ en-US ] = "Beginner"\ +   +      #define ITEM_CHANGEUSERLEVEL_AVERAGE \ +   Identifier = SID_CHANGUSERLEVEL_AVERAGE ; \ +	Command = ".uno:SetUserLevelAverage" ; \ +   HelpID = SID_CHANGUSERLEVEL_AVERAGE ; \ +   Text [ en-US ] = "Average"\ +   +    +      #define ITEM_CHANGEUSERLEVEL_EXPERT \ +   Identifier = SID_CHANGUSERLEVEL_EXPERT ; \ +	Command = ".uno:ChangeUserLevel" ; \ +   HelpID = SID_CHANGUSERLEVEL_EXPERT ; \ +   Text [ en-US ] = "Expert";\ + +#define ITEM_CHANGEUSERLEVEL_MENU \ + MenuItem\ +   {\ +	Identifier = SID_CHANGEUSERLEVEL_MENU ; \ +	Command = ".uno:ChangeUserLevel" ; \ +	HelpID = SID_CHANGEUSERLEVEL_MENU ; \ +	Text [ en-US ] = "Change User Level" ; \ +	SubMenu = Menu\ +	{\ +	ItemList = \ +	 {\ +	   MenuItem\ +		{\ +		 ITEM_CHANGEUSERLEVEL_BEGINNER ;\ +		};\ +	  MenuItem\ +		{\ +		ITEM_CHANGEUSERLEVEL_AVERAGE ;\ +		};\ +	 MenuItem\ +		{\ +		ITEM_CHANGEUSERLEVEL_EXPERT ;\ +		};\ +	 };\ +	};\ +  };\

- 03-02-2011
IRC Meeting

ericb:que se passe-t-il quand on ajoute des entrees de menus ? (qu'est ce qui est modifie dans les preferences ?)

- 10-02-2011
IRC Meeting

1.	Changes made in sfx2 directory
I added code to the method SfxApplication::OfaExec_Impl to handle the case for the new slots. Once user chooses the level and clicks on entry, it will remove the previous toolbar level and adapt to the user

choice. It will also change userlevel in officecfg/registry/data/org/openoffice/Office/Common.xcu which contains current userlevel and set it to the new level chosen by the user.

setUserLevel used for changing current user level in Common.xcu and setToolbarState used to set the correct toolbar. Tested and works.

Index: sfx2/source/appl/appserv.cxx

=
====================================================== --- sfx2/source/appl/appserv.cxx	(révision 1150) +++ sfx2/source/appl/appserv.cxx	(copie de travail) @@ -153,8 +153,93 @@ using namespace ::com::sun::star::document; namespace css = com::sun::star; +//- +#define USER_LEVEL_BEGINNER     1 +#define USER_LEVEL_AVERAGE      2 +#define USER_LEVEL_EXPERT       3 +#include  +using ::rtl::OUString; +#include  +#include  +static const OUString sStandardbarToolbarTypeName( RTL_CONSTASCII_USTRINGPARAM( "private:resource/toolbar/standardbar" ) ); +// The beginner toolbar (every application has its own) +static const OUString sBeginnerbarToolbarTypeName( RTL_CONSTASCII_USTRINGPARAM( "private:resource/toolbar/beginner" ) ); +// The average toolbar (every application has its own) +static const OUString sAveragebarToolbarTypeName( RTL_CONSTASCII_USTRINGPARAM( "private:resource/toolbar/average" ) ); +static const OUString sULConfigSrvc( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.configuration.ConfigurationProvider" ) ); +static const OUString sULAccessSrvc( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.configuration.ConfigurationUpdateAccess" ) ); +static const OUString sULaNode( RTL_CONSTASCII_USTRINGPARAM( "/org.openoffice.Office.Common/Misc" ) ); +static const OUString sULPropertyName( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "UserLevel" ) ) ); +static const OUString aLayoutManagerPropName( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ) ); //- +static short setToolbarState( const OUString sSetAToolbarTypeName, bool isTrue ) +{ +   try +   { +        // avoids a crash if ever the user opens the prefs while the start center is the current view +       if ( ! (SfxViewFrame::Current) ) +           return -1; +       +        Reference< XPropertySet > xPropSet( SfxViewFrame::Current->GetFrame->GetFrameInterface, UNO_QUERY ); +       Reference< XLayoutManager > xLayoutManager; + +       if ( xPropSet.is ) +       { +            Any aValue = xPropSet->getPropertyValue( aLayoutManagerPropName ); +           aValue >>= xLayoutManager; +       } + +        if ( !xLayoutManager.is ) +           return -1; +       else +       { +            xLayoutManager->lock; + +           if ( isTrue ) +           { +                // requestElement adds ghosts of the alignmentar (bug ?) +               xLayoutManager->requestElement( sSetAToolbarTypeName ); +               //xLayoutManager->showElement( sSetAToolbarTypeName ); +           } +            else +               xLayoutManager->destroyElement( sSetAToolbarTypeName ); + +           // should refresh, but does not when showElement is used +           xLayoutManager->unlock; +       } +    } +    catch( Exception& ) +   { +    } +    return 0; +} + +static void setUserLevel( short nLevel ) +{ +   try +   { +        Reference < XMultiServiceFactory > xFactory = ::comphelper::getProcessServiceFactory; +       // get configuration provider +       Reference< XMultiServiceFactory > theConfigProvider = Reference< XMultiServiceFactory >( +        xFactory->createInstance(sULConfigSrvc), UNO_QUERY_THROW); +       Sequence< Any > theArgs(1); +       NamedValue v(OUString::createFromAscii("NodePath"), +            makeAny(OUString::createFromAscii("org.openoffice.Office.Common/Misc"))); +       theArgs[0] <<= v; +        Reference< XPropertySet > pset = Reference< XPropertySet >( +            theConfigProvider->createInstanceWithArguments(sULAccessSrvc, theArgs), UNO_QUERY_THROW); + +       Any result = pset->getPropertyValue(OUString::createFromAscii("UserLevel")); + +       pset->setPropertyValue(OUString::createFromAscii("UserLevel"), makeAny(nLevel)); +       Reference< XChangesBatch >(pset, UNO_QUERY_THROW)->commitChanges; +   } +    catch( Exception& ) +   { +    } +} +//- long QuitAgain_Impl( void* pObj, void* pArg ) { 	SfxApplication* pApp = (SfxApplication*)pObj; @@ -560,7 +645,33 @@ 			bDone = TRUE; break; } +	// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +	case SID_CHANGUSERLEVEL_BEGINNER : +	{ +		setUserLevel( USER_LEVEL_BEGINNER ); +           setToolbarState( sStandardbarToolbarTypeName, false ); +           setToolbarState( sBeginnerbarToolbarTypeName, true ); +           setToolbarState( sAveragebarToolbarTypeName, false); +	break; +	} +	case SID_CHANGUSERLEVEL_AVERAGE: +	{ +		setUserLevel( USER_LEVEL_AVERAGE ); +           setToolbarState( sStandardbarToolbarTypeName, false ); +           setToolbarState( sBeginnerbarToolbarTypeName, false ); +           setToolbarState( sAveragebarToolbarTypeName, true); +	break; +	} + +	case SID_CHANGUSERLEVEL_EXPERT : +	{ +	 	setUserLevel( USER_LEVEL_EXPERT ); +           setToolbarState( sStandardbarToolbarTypeName, true ); +           setToolbarState( sBeginnerbarToolbarTypeName, false ); +           setToolbarState( sAveragebarToolbarTypeName, false); +	break; +	} 	// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Index: sfx2/sdi/appslots.sdi

=
====================================================== --- sfx2/sdi/appslots.sdi	(révision 1150) +++ sfx2/sdi/appslots.sdi	(copie de travail) @@ -56,6 +56,18 @@ 	[ 		ExecMethod = MiscExec_Impl ; ] +       SID_CHANGUSERLEVEL_BEGINNER +	[ +		ExecMethod = MiscExec_Impl ; +	] +       SID_CHANGUSERLEVEL_AVERAGE +	[ +		ExecMethod = MiscExec_Impl ; +	] +       SID_CHANGUSERLEVEL_EXPERT +	[ +		ExecMethod = MiscExec_Impl ; +	] 	SID_SETOPTIONS [ 		ExecMethod = MiscExec_Impl ; Index: sfx2/sdi/sfx.sdi

inspired from SID_ABOUT

--- sfx2/sdi/sfx.sdi	(révision 1150) +++ sfx2/sdi/sfx.sdi	(copie de travail) @@ -30,6 +30,103 @@ ************************************************************************/

+ //-- +SfxVoidItem SetUserLevelBeginner SID_CHANGUSERLEVEL_BEGINNER + +[ +	/* flags: */ +	AutoUpdate = FALSE, +	Cachable = Cachable, +	FastCall = FALSE, +	HasCoreId = FALSE, +	HasDialog = TRUE, +	ReadOnlyDoc = TRUE, +	Toggle = FALSE, +	Container = FALSE, +	RecordAbsolute = FALSE, +	RecordPerSet; +	Synchron; + +	/* config: */ +	AccelConfig = TRUE, +	MenuConfig = TRUE, +	StatusBarConfig = FALSE, +	ToolBoxConfig = TRUE, +	GroupId = GID_APPLICATION; +] +//-- +SfxVoidItem SetUserLevelAverage SID_CHANGUSERLEVEL_AVERAGE + +[ +	/* flags: */ +	AutoUpdate = FALSE, +	Cachable = Cachable, +	FastCall = FALSE, +	HasCoreId = FALSE, +	HasDialog = FALSE, +	ReadOnlyDoc = TRUE, +	Toggle = FALSE, +	Container = FALSE, +	RecordAbsolute = FALSE, +	RecordPerSet; +	Synchron; + +	/* config: */ +	AccelConfig = TRUE, +	MenuConfig = TRUE, +	StatusBarConfig = FALSE, +	ToolBoxConfig = TRUE, +	GroupId = GID_APPLICATION; +] +//-- +SfxVoidItem SetUserLevelExpert SID_CHANGUSERLEVEL_EXPERT + +[ +	/* flags: */ +	AutoUpdate = FALSE, +	Cachable = Cachable, +	FastCall = FALSE, +	HasCoreId = FALSE, +	HasDialog = FALSE, +	ReadOnlyDoc = TRUE, +	Toggle = FALSE, +	Container = FALSE, +	RecordAbsolute = FALSE, +	RecordPerSet; +	Synchron; + +	/* config: */ +	AccelConfig = TRUE, +	MenuConfig = TRUE, +	StatusBarConfig = FALSE, +	ToolBoxConfig = TRUE, +	GroupId = GID_APPLICATION; +]

2.	Changes made in officecfg  directory
Index: officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu

=
====================================================== --- officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu	(révision 1150) +++ officecfg/registry/data/org/openoffice/Office/UI/GenericCommands.xcu	(copie de travail) @@ -4584,6 +4584,42 @@ 			   使用授權… +			 +				 +					Change User Level +					Changer le niveau d'utilisateur +				 +				 +					 0 +				 				+			 +			 +				 +					Beginner +					Debutant +				 +				 +					 1 +				 				+			 +			<node oor:name=".uno:SetUserLevelAverage" oor:op="replace"> +				<prop oor:name="Label" oor:type="xs:string"> +					<value xml:lang="en-US">Average +					<value xml:lang="fr">Moyen +				 +				<prop oor:name="Properties" oor:type="xs:int"> +					 2 +				 +			 +			<node oor:name=".uno:SetUserLevelExpert" oor:op="replace"> +				<prop oor:name="Label" oor:type="xs:string"> +					<value xml:lang="en-US">Expert +					<value xml:lang="fr">Expert +				 +				<prop oor:name="Properties" oor:type="xs:int"> +					 3 +				 				+			 			<node oor:name=".uno:PrinterSetup" oor:op="replace"> <prop oor:name="Label" oor:type="xs:string"> <value xml:lang="en-US">P~rinter Settings...

3.	Changes made In svx directory
This particular piece of code doesn’t work. I am trying to figure it out.

Here I am trying to create a menu with 3 submenus which is a member of ITEM_HELP.

Index: svx/inc/globlmn_tmpl.hrc

=
====================================================== --- svx/inc/globlmn_tmpl.hrc	(révision 1150) +++ svx/inc/globlmn_tmpl.hrc	(copie de travail) @@ -1087,6 +1087,54 @@    Text [ it ] = "L~icenza..."; \ Text [ pt ] = "L~icenca..."; \ +#define ITEM_HELP_CHANGEUSERLEVEL_BEGINNER \ +   Identifier = SID_CHANGUSERLEVEL_BEGINNER ; \ +   Command = ".uno:SetUserLevelBeginner" ; \ +   HelpID = SID_CHANGUSERLEVEL_BEGINNER ; \ +   	Text [ en-US ] = "Beginner"; \ +  	Text [ fr ] = "Debutant" ; \ +  +#define ITEM_HELP_CHANGEUSERLEVEL_AVERAGE \ +   Identifier = SID_CHANGUSERLEVEL_AVERAGE ; \ +   Command = ".uno:SetUserLevelAverage" ; \ +   HelpID = SID_CHANGUSERLEVEL_AVERAGE ; \ +  	Text [ en-US ] = "Average"; \ +  	Text [ fr ] = "Moyen" ; \ +   +#define ITEM_HELP_CHANGEUSERLEVEL_EXPERT \ +   Identifier = SID_CHANGUSERLEVEL_EXPERT ; \ +   Command = ".uno:SetUserLevelExpert" ; \ +   HelpID = SID_CHANGUSERLEVEL_EXPERT ; \ +   	Text [ en-US ] = "Expert";\ +  	Text [ fr ] = "Expert" ; \ + +#define ITEM_HELP_CHANGEUSERLEVEL_MENU \ + MenuItem\ +   {\ +	Identifier = SID_CHANGUSERLEVEL_MENU  ; \ +	Command = ".uno:ChangeUserLevel" ; \ +	HelpID = SID_CHANGUSERLEVEL_MENU ; \ +	Text [ en-US ] = "Change User Level" ; \ +  	Text [ fr ] = "Changer Le Niveau D'Utilisateur" ; \ +	SubMenu = Menu\ +	{\ +	ItemList = \ + {\ +	   MenuItem\ +		{\ +		 ITEM_HELP_CHANGEUSERLEVEL_BEGINNER ;\ +		};\ +	 MenuItem\ +		{\ +		ITEM_HELP_CHANGEUSERLEVEL_AVERAGE ;\ +		};\ +	 MenuItem\ +		{\ +		ITEM_HELP_CHANGEUSERLEVEL_EXPERT ;\ +		};\ +	 };\ +	};\ +  };\



Diff of modifications
the diff contains all modification in sfx2 and officecfg for 3 entry menu for each level Beginner,average,expert ,

svx part is not in this diff i tested it in french version it works havent tested yet in english version.

link for download : Click here

- 17-02-2011
IRC Meeting

la reponse a la question qui a ete posee il ya deux semaines question : que se passe-t-il quand on ajoute des entrees de menus, en particulier dans les prefs de l'utilisateur

reponse par ericb dans le meeting

Ericb:quand on demarre un profil neuf, les fichiers initiaux sont dans le st d'installation ensuite, si l'utilisateur fait une modification, alors le fichier .xcu ou .xml (pour les menus) correspondant, est RECOPIE dans les preferences et c'est celui-ci qui sera trouve en premier c'est la raison pour laquelle, si on supprime le profil, on retrouve les reglages de base point important: on recherche les fichies .xcu et .xml dans le profil utilisateur, et s'ils ne sont pas trouves (ce qui signifie qu'aucune modification n'a ete faite), alors on lit les fichiers par defaut (dans le set ) encore pour mieux comprendre :

Ericb: imagine que tu veuilles changer le niveau utilisateur si c'est la premiere modification, on ecrit un nouveau fichier dans les prefs utilisateur comment lit-on/ecrit-on ? c'est un point cle on utilise UNO l'api permet de lire ecrire, et le framework s'occupe de creer les fichiers qui manquent, au bon endroit pour lire, il faut creer une interface. Cela signifie un "service" UNO et dans le code que tu as ecrit avec Julien, tu "instancie" une interface UNO, tu lui dis quel champ .xml il faut retrouver, et si tout va bien, tu ecrit le nouveau l'api UNO fait donc le lien entre le code C++ pur, et les fichiers xml / xcu

- objective
Devoir a Faire comprendre, et expliquer ce qui permet d'ajouter une entree de menus (meme inactive).

sd/uiconfig/sdraw, sd/uiconfig/impress sw/uiconfig/swriter sc/uiconfig/scalc a quoi servent-ils ? Et que se passe-t-il quand tu ajoutes une entree de menu dans les prefs utilisateur le mecanisme est le meme que pour les .xcu au passage, mais il faudra toruver ou ils sont ecrits dans les prefs utilisateur

- 21-02-2011
accelerator, menubar, statusbar and toolbar which exists in $src_root / sw / uiconfig / swriter

$src_root / sd / uiconfig / sdraw

$src_root / sd / uiconfig / impress

$src_root / sw / uiconfig / swriter

are respectively used for:

accelerator: Used for creating and assigning a hot-key to a menu entry in (draw, calc,writer,impress).

menubar: contains the standard bar in	(draw, calc,writer,impress).

statusbar: represents the bar at the bottom in (draw, calc,writer,impress) which contains properties such as (zoom + ,-) etc.

toolbar: contains properties for each bar in(draw, calc, etc.)

I have deliberately added the following line <menu:menuitem menu:id=".uno:ChangeUserLevel"/> (I have already declared the slot and id for ChangeUserLevel in $src_root/sfx2 )

at line 156, right after .uno:ShowLicense in $src_root/sw/uiconfig/swriter/menubar/menubar.xml, just to see what is the result, snapshot of what result i achieved, a menu entry

appears by default into help menu in writer.

change in $src_root / sw / uiconfig / swriter/menubar/menubar.xml



and the result



- Change User Level Entry with submenus
creation of a menu item in the menu-format which contains three sub-menus (Beginner, Intermediate, Expert)

the entries (Beginner, Intermediate, Expert) who were previously in customize-> keyboard-> application are now in customize-> keyboard-> Format

Added a slot for changeuseerlevel in $ src_root/sfx2/sdi/sfx.sdi

+SfxVoidItem ChangeUserLevel SID_CHANGEUSERLEVEL_MENU + +[ +	/* flags: */ +	AutoUpdate = FALSE, +	Cachable = Cachable, +	FastCall = TRUE, +	HasCoreId = FALSE, +	HasDialog = FALSE, +	ReadOnlyDoc = FALSE, +	Toggle = FALSE, +	Container = FALSE, +	RecordAbsolute = FALSE, +	RecordPerSet; +	Synchron; + +	Readonly = FALSE, + +	/* config: */ +	AccelConfig = FALSE, +	MenuConfig = FALSE, +	StatusBarConfig = FALSE, +	ToolBoxConfig = TRUE, +	GroupId = GID_FORMAT; +	PseudoSlots = TRUE; +	PseudoPrefix = SID_CHANGEUSERLEVEL_MENU; +]

et definition de la function qui va prendre en charge ce slot dans $src_root/sfx2/sdi/appslots.sdi

+       SID_CHANGEUSERLEVEL_MENU +	[ +		ExecMethod = MiscExec_Impl ; +	]

changes realized in $src_root/svx/inc/globlmn_tmpl.hrc :

+#define ITEM_FORMAT_CHANGEUSERLEVEL_BEGINNER \ +   Identifier = SID_CHANGEUSERLEVEL_BEGINNER ; \ +   Command = ".uno:SetUserLevelBeginner" ; \ +   HelpID = SID_CHANGEUSERLEVEL_BEGINNER ; \ +   	Text [ en-US ] = "~Beginner"; \ +  	Text [ fr ] = "~Debutant" ; \ +  +#define ITEM_FORMAT_CHANGEUSERLEVEL_AVERAGE \ +   Identifier = SID_CHANGEUSERLEVEL_AVERAGE ; \ +   Command = ".uno:SetUserLevelAverage" ; \ +   HelpID = SID_CHANGEUSERLEVEL_AVERAGE ; \ +  	Text [ en-US ] = "~Average"; \ +  	Text [ fr ] = "~Moyen" ; \ +   +#define ITEM_FORMAT_CHANGEUSERLEVEL_EXPERT \ +   Identifier = SID_CHANGEUSERLEVEL_EXPERT ; \ +   Command = ".uno:SetUserLevelExpert" ; \ +   HelpID = SID_CHANGUSERLEVEL_EXPERT ; \ +   	Text [ en-US ] = "~Expert";\ +  	Text [ fr ] = "~Expert" ; \ + +#define ITEM_FORMAT_CHANGEUSERLEVEL_MENU \ +	Identifier = SID_CHANGEUSERLEVEL_MENU ; \ +	Command = ".uno:ChangeUserLevel" ; \ +	HelpID = SID_CHANGEUSERLEVEL_MENU ; \ +	Text [ en-US ] = "~Change User Level" ; \ +  	Text [ fr ] = "~Changer Le Niveau D'Utilisateur" ; \

added in $Src_root/sw/uiconfig/swriter/menubar/menubar.xml

+  <menu:menu menu:id=".uno:ChangeUserLevel" menu:label=""> +   <menu:menupopup> +    <menu:menuitem menu:id=".uno:SetUserLevelBeginner"/> +    <menu:menuitem menu:id=".uno:SetUserLevelAverage"/> +    <menu:menuitem menu:id=".uno:SetUserLevelExpert"/> +   </menu:menupopup> +  </menu:menu> +  <menu:menuseparator/>



et at last change in :

+			<node oor:name=".uno:ChangeUserLevel" oor:op="replace"> +				<prop oor:name="Label" oor:type="xs:string"> +					<value xml:lang="en-US">~Change User Level +					<value xml:lang="fr">~Changer le niveau d'utilisateur +				 +				<prop oor:name="Properties" oor:type="xs:int"> +					 1 +				 				+

the the entry menu which will contain submenu must be between.



snapshot of the result that i got:



- some improvements in entry menu
i have done some changes in diff because of some values weren't relevant and there was some spelling fault that i corrected here is what i done:

1. I changed the name entry menu ,it was before (changer le niveau d'utilistauer). changed to (user level). name was little bit long and wasn't relevent.

2. avant il apparaissait par defaut dans le menu-format. désormais il est dans le menu-affichage.

3. I also deleted the piece of code I had written in $src_root/svx/inc/globlmn_tmpl.hrc.

this is the part that been removed from diff.

+#define ITEM_FORMAT_CHANGEUSERLEVEL_BEGINNER \ +   Identifier = SID_CHANGEUSERLEVEL_BEGINNER ; \ +   Command = ".uno:SetUserLevelBeginner" ; \ +   HelpID = SID_CHANGEUSERLEVEL_BEGINNER ; \ +   	Text [ en-US ] = "~Beginner"; \ +  	Text [ fr ] = "~Debutant" ; \ +  +#define ITEM_FORMAT_CHANGEUSERLEVEL_AVERAGE \ +   Identifier = SID_CHANGEUSERLEVEL_AVERAGE ; \ +   Command = ".uno:SetUserLevelAverage" ; \ +   HelpID = SID_CHANGEUSERLEVEL_AVERAGE ; \ +  	Text [ en-US ] = "~Average"; \ +  	Text [ fr ] = "~Moyen" ; \ +   +#define ITEM_FORMAT_CHANGEUSERLEVEL_EXPERT \ +   Identifier = SID_CHANGEUSERLEVEL_EXPERT ; \ +   Command = ".uno:SetUserLevelExpert" ; \ +   HelpID = SID_CHANGUSERLEVEL_EXPERT ; \ +   	Text [ en-US ] = "~Expert";\ +  	Text [ fr ] = "~Expert" ; \ + +#define ITEM_FORMAT_CHANGEUSERLEVEL_MENU \ +	Identifier = SID_CHANGEUSERLEVEL_MENU ; \ +	Command = ".uno:ChangeUserLevel" ; \ +	HelpID = SID_CHANGEUSERLEVEL_MENU ; \ +	Text [ en-US ] = "~Change User Level" ; \ +  	Text [ fr ] = "~Changer Le Niveau D'Utilisateur" ; \

4.changed SID in $src_root/sfx2/sfx/sfxsids to :

+SID_CHANGEUSERLEVEL +SID_CHANGUSERLEVELBEGINNER +SID_CHANGEUSERLEVELAVERAGE +SID_CHANGEUSERLEVELEXPERT



just for record the current configuration that i use in linux for build is

./configure --with-OOo4Kids --disable-gnome-vfs --with-system-libxml --with-lang="fr"

everything that i've done, tested in ooo4kids writer french version,i haven't tested it yet in english version.

- 24-02-2011
devoir a faire

trying to find a solution (creating class or something) instead using static functions such as setuserlevel in

the appserv.cxx in $src_root/sfx2/source/app/appser.cxx, the static functions that i picked from workwin.cxx in same directory

to change user level in officecfg and adapte correct toolbar to user choice.

- during last days
je suis entrain de faire mon rapport de stage (staged'insertion socioprofessionnelle)

et je fait un projet en visual basic 6 pour l'ecole je n'ai pas pu faire grand chose ces dernier jours

je vais essayer de terminer rapport de stage et mon projet pour la fin de semaine