Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédente | |||
| configuration-avancee-unity-2d [Le 31/05/2012, 15:12] – d'en faire en une sauvegarde > d'en faire une sauvegarde, afficher la fonction que vous avez choisi > afficher la fonction que vous avez choisie Canigou 66 | configuration-avancee-unity-2d [Le 12/07/2017, 11:42] (Version actuelle) – obsolète L'Africain | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| - | {{tag> | ||
| - | ---- | ||
| - | ====== Configuration avancée d' | ||
| - | Les outils étant encore rares, voire inexistants, | ||
| - | Notez cependant que les changements réalisés affecteront tous les utilisateurs du système et pas seulement vous. S'il y a plus d'un utilisateur sur votre PC, demandez leur avis avant d' | ||
| - | |||
| - | < | ||
| - | |||
| - | <note important> | ||
| - | |||
| - | Et si toutefois la configuration ne fonctionnait pas et la restauration du fichier d' | ||
| - | < | ||
| - | où < | ||
| - | * // | ||
| - | * // | ||
| - | * // | ||
| - | * // | ||
| - | </ | ||
| - | |||
| - | ===== Le tableau de bord : Home Dash ===== | ||
| - | ==== Modifier la fonction d' | ||
| - | |||
| - | Ceci rendra l' | ||
| - | |||
| - | * [[: | ||
| - | * Cherchez vers la ligne 110 la fonction **function activateHome() {** | ||
| - | * Retirez le contenu de cette fonction en faisant attention aux parenthèses (il faut bien supprimer jusqu' | ||
| - | } | ||
| - | </ | ||
| - | * Ajoutez entre les accolades // | ||
| - | * **applications.lens** pour les applications | ||
| - | * **commands.lens** pour saisir une commande | ||
| - | * **files.lens** pour accéder au fichier | ||
| - | * **music.lens** pour accéder au dossier **Musique** dans votre //Dossier Personnel// | ||
| - | Après modification, | ||
| - | <code cpp-qt> | ||
| - | activateLens(" | ||
| - | } | ||
| - | </ | ||
| - | Au prochain démarrage d' | ||
| - | |||
| - | ==== Retirer l' | ||
| - | === Unity 2D <= 5.4 === | ||
| - | * [[: | ||
| - | * Chercher vers la ligne 96 un code similaire à celui-ci: <code cpp-qt> | ||
| - | LensButton { | ||
| - | id: homeLens | ||
| - | |||
| - | Accessible.name: | ||
| - | |||
| - | focus: true | ||
| - | icon: " | ||
| - | onClicked: dash.activateHome() | ||
| - | active: ( dashView.activeLens == "" | ||
| - | iconWidth: lensBar.iconWidth | ||
| - | iconSpacing: | ||
| - | width: iconWidth+iconSpacing | ||
| - | height: lensContainer.height | ||
| - | } | ||
| - | </ | ||
| - | * Remplacez-le par : <code cpp-qt> | ||
| - | LensButton { | ||
| - | id: homeLens | ||
| - | |||
| - | Accessible.name: | ||
| - | |||
| - | focus: false | ||
| - | icon: "" | ||
| - | onClicked: dash.activateHome() | ||
| - | active: | ||
| - | iconWidth: 0 | ||
| - | iconSpacing: | ||
| - | width: 0 | ||
| - | height: 0 | ||
| - | } | ||
| - | </ | ||
| - | La lens //Home// ne devrait plus s' | ||
| - | |||
| - | === Unity 2D >= 5.4 === | ||
| - | * [[: | ||
| - | * Chercher un code similaire à celui-ci (proche de la ligne 97) : <code cpp-qt> | ||
| - | id: repeater | ||
| - | |||
| - | model: visibleLenses | ||
| - | delegate: LensButton { | ||
| - | Accessible.name: | ||
| - | |||
| - | /* Heuristic: if iconHint does not contain a '/' | ||
| - | icon: { | ||
| - | if (item.id == " | ||
| - | return " | ||
| - | } | ||
| - | item.iconHint.indexOf("/" | ||
| - | } | ||
| - | active: { | ||
| - | /* we need this in order to activate the arrow when using a custom shortcuts file */ | ||
| - | if (item.id == " | ||
| - | return true | ||
| - | } | ||
| - | return item.viewType == Lens.LensView | ||
| - | } | ||
| - | onClicked: { | ||
| - | if (item.id == " | ||
| - | dash.activateHome() | ||
| - | } else { | ||
| - | dash.activateLens(item.id) | ||
| - | } | ||
| - | } | ||
| - | iconWidth: lensBar.iconWidth | ||
| - | iconSpacing: | ||
| - | width: iconWidth+iconSpacing | ||
| - | height: lensContainer.height | ||
| - | } | ||
| - | } | ||
| - | </ | ||
| - | * Remplacez-le par : <code cpp-qt> | ||
| - | id: repeater | ||
| - | |||
| - | model: visibleLenses | ||
| - | delegate: LensButton { | ||
| - | Accessible.name: | ||
| - | |||
| - | /* Heuristic: if iconHint does not contain a '/' | ||
| - | icon: { | ||
| - | if (item.id == " | ||
| - | return "" | ||
| - | } | ||
| - | item.iconHint.indexOf("/" | ||
| - | } | ||
| - | active: { | ||
| - | return item.viewType == Lens.LensView | ||
| - | } | ||
| - | onClicked: { | ||
| - | dash.activateLens(item.id) | ||
| - | } | ||
| - | iconWidth: lensBar.iconWidth | ||
| - | iconSpacing: | ||
| - | width: iconWidth+iconSpacing | ||
| - | height: lensContainer.height | ||
| - | } | ||
| - | } | ||
| - | </ | ||
| - | |||
| - | ===== Les loupes ===== | ||
| - | ==== Avoir les loupe en haut à droite du Tableau de bord ==== | ||
| - | <note important> | ||
| - | |||
| - | * [[: | ||
| - | * Cherchez ce code : <code cpp-qt> | ||
| - | Item { | ||
| - | id: content | ||
| - | |||
| - | anchors.fill: | ||
| - | /* Margins in DesktopMode set so that the content does not overlap with | ||
| - | the border defined by the background image. | ||
| - | */ | ||
| - | anchors.bottomMargin: | ||
| - | anchors.rightMargin: | ||
| - | |||
| - | /* Unhandled keys will always be forwarded to the search bar. That way | ||
| - | the user can type and search from anywhere in the interface without | ||
| - | | ||
| - | /* FIXME: deactivated because it makes the user lose the focus very often */ | ||
| - | // | ||
| - | |||
| - | SearchEntry { | ||
| - | id: search_entry | ||
| - | |||
| - | focus: true | ||
| - | /* FIXME: check on visible necessary; fixed in Qt Quick 1.1 | ||
| - | ref: http:// | ||
| - | */ | ||
| - | KeyNavigation.right: | ||
| - | KeyNavigation.down: | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.left: | ||
| - | anchors.leftMargin: | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | |||
| - | height: 42 | ||
| - | |||
| - | active: dash.active | ||
| - | placeHolderText: | ||
| - | if(dash.currentPage != undefined && dash.currentPage.model.searchHint) | ||
| - | return dash.currentPage.model.searchHint | ||
| - | else | ||
| - | return u2d.tr(" | ||
| - | } | ||
| - | |||
| - | onSearchQueryChanged: | ||
| - | onActivateFirstResult: | ||
| - | } | ||
| - | |||
| - | FilterPane { | ||
| - | id: filterPane | ||
| - | |||
| - | KeyNavigation.left: | ||
| - | |||
| - | /* FilterPane is only to be displayed for lenses, not in the home page or Alt+F2 Run page */ | ||
| - | visible: declarativeView.activeLens != " | ||
| - | lens: visible && currentPage != undefined ? currentPage.model : undefined | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.bottom: | ||
| - | headerHeight: | ||
| - | width: 300 | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | } | ||
| - | |||
| - | Loader { | ||
| - | id: pageLoader | ||
| - | objectName: " | ||
| - | |||
| - | Accessible.name: | ||
| - | /* FIXME: check on visible necessary; fixed in Qt Quick 1.1 | ||
| - | ref: http:// | ||
| - | */ | ||
| - | KeyNavigation.right: | ||
| - | KeyNavigation.up: | ||
| - | KeyNavigation.down: | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.bottom: | ||
| - | anchors.left: | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | onLoaded: item.focus = true | ||
| - | |||
| - | /* Workaround loss of focus issue happening when the loaded item has | ||
| - | | ||
| - | lost instead of being relinquished to the Loader. | ||
| - | |||
| - | Ref.: https:// | ||
| - | */ | ||
| - | function setSource(newSource) { | ||
| - | var hadActiveFocus = activeFocus | ||
| - | source = newSource | ||
| - | if (hadActiveFocus) forceActiveFocus() | ||
| - | } | ||
| - | } | ||
| - | |||
| - | LensBar { | ||
| - | id: lensBar | ||
| - | |||
| - | KeyNavigation.up: | ||
| - | |||
| - | anchors.bottom: | ||
| - | anchors.left: | ||
| - | anchors.right: | ||
| - | height: 44 | ||
| - | visible: declarativeView.expanded | ||
| - | } | ||
| - | } | ||
| - | </ | ||
| - | * Remplacez-le par : <code cpp-qt> | ||
| - | Item { | ||
| - | id: content | ||
| - | |||
| - | anchors.fill: | ||
| - | /* Margins in DesktopMode set so that the content does not overlap with | ||
| - | the border defined by the background image. | ||
| - | */ | ||
| - | anchors.bottomMargin: | ||
| - | anchors.rightMargin: | ||
| - | |||
| - | visible: dashView.active | ||
| - | |||
| - | /* Unhandled keys will always be forwarded to the search bar. That way | ||
| - | the user can type and search from anywhere in the interface without | ||
| - | | ||
| - | /* FIXME: deactivated because it makes the user lose the focus very often */ | ||
| - | // | ||
| - | |||
| - | |||
| - | SearchEntry { | ||
| - | id: search_entry | ||
| - | |||
| - | focus: true | ||
| - | /* FIXME: check on visible necessary; fixed in Qt Quick 1.1 | ||
| - | ref: http:// | ||
| - | */ | ||
| - | KeyNavigation.right: | ||
| - | KeyNavigation.down: | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.left: | ||
| - | anchors.leftMargin: | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | |||
| - | height: 42 | ||
| - | } | ||
| - | |||
| - | LensBar { | ||
| - | id: lensBar | ||
| - | |||
| - | KeyNavigation.up: | ||
| - | | ||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.left: | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | | ||
| - | height: 42 | ||
| - | } | ||
| - | |||
| - | Loader { | ||
| - | id: pageLoader | ||
| - | |||
| - | Accessible.name: | ||
| - | /* FIXME: check on visible necessary; fixed in Qt Quick 1.1 | ||
| - | ref: http:// | ||
| - | */ | ||
| - | KeyNavigation.right: | ||
| - | KeyNavigation.up: | ||
| - | KeyNavigation.down: | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.bottom: | ||
| - | anchors.left: | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | onLoaded: item.focus = true | ||
| - | } | ||
| - | | ||
| - | FilterPane { | ||
| - | id: filterPane | ||
| - | |||
| - | KeyNavigation.left: | ||
| - | |||
| - | /* FilterPane is only to be displayed for lenses, not in the home page or Alt+F2 Run page */ | ||
| - | visible: dashView.activeLens != "" | ||
| - | lens: visible && currentPage != undefined ? currentPage.model : undefined | ||
| - | |||
| - | anchors.top: | ||
| - | anchors.topMargin: | ||
| - | anchors.bottom: | ||
| - | headerHeight: | ||
| - | width: 300 | ||
| - | anchors.right: | ||
| - | anchors.rightMargin: | ||
| - | } | ||
| - | } | ||
| - | </ | ||
| - | |||
| - | ==== Retirer le rectangle noir transparent derrière les loupes | ||
| - | |||
| - | * [[: | ||
| - | * Dans le haut du fichier, cherchez :<code cpp-qt > | ||
| - | FocusScope { | ||
| - | id: lensBar | ||
| - | |||
| - | /* declare width & spacing of icons as required for layout calculations */ | ||
| - | property int iconWidth: 24 | ||
| - | property int iconSpacing: | ||
| - | |||
| - | property variant visibleLenses: | ||
| - | model: dash.lenses | ||
| - | dynamicSortFilter: | ||
| - | |||
| - | filterRole: Lenses.RoleVisible | ||
| - | filterRegExp: | ||
| - | } | ||
| - | |||
| - | Rectangle { | ||
| - | id: background | ||
| - | |||
| - | anchors.fill: | ||
| - | color: " | ||
| - | opacity: 0.22 | ||
| - | } | ||
| - | </ | ||
| - | * Remplacez **opacity: 0.22** par **opacity: 0** | ||
| - | |||
| - | ---- | ||
| - | // | ||
