You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by mw...@apache.org on 2013/07/25 00:13:06 UTC

[11/12] docs commit: [CB-3816] corrected 'merges' content; mirrors src tree, doesn't map files in flat dir

[CB-3816] corrected 'merges' content; mirrors src tree, doesn't map files in flat dir


Project: http://git-wip-us.apache.org/repos/asf/cordova-docs/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-docs/commit/db19cf23
Tree: http://git-wip-us.apache.org/repos/asf/cordova-docs/tree/db19cf23
Diff: http://git-wip-us.apache.org/repos/asf/cordova-docs/diff/db19cf23

Branch: refs/heads/master
Commit: db19cf23dfea4b5f400fc7edbfe74cfbc8f1dfa6
Parents: 636109a
Author: Mike Sierra <le...@gmail.com>
Authored: Tue Jul 23 15:02:19 2013 -0400
Committer: Michael Brooks <mi...@michaelbrooks.ca>
Committed: Wed Jul 24 15:12:01 2013 -0700

----------------------------------------------------------------------
 docs/en/edge/guide/cli/index.md | 41 ++++++++++++++++++++++--------------
 1 file changed, 25 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/db19cf23/docs/en/edge/guide/cli/index.md
----------------------------------------------------------------------
diff --git a/docs/en/edge/guide/cli/index.md b/docs/en/edge/guide/cli/index.md
index 520af1d..bdb8d97 100644
--- a/docs/en/edge/guide/cli/index.md
+++ b/docs/en/edge/guide/cli/index.md
@@ -278,35 +278,44 @@ argument for each command.
 
 ## Customize each Platform
 
-While Cordova allows you to easily build apps for different platforms,
-sometimes you need to add customizations.  In that case, you don't
-want to modify the CSS in various `www` directories within the
-top-level `platforms` directory, because they're regularly replaced
-with the top-level `www` directory's cross-platform source.  Instead,
-the top-level `merges` directory offers a place to specify assets to
-be deployed for specific platforms. Any file you place in a platform's
-subdirectory replaces a corresponding file within the top-level `www`
-source tree.
-
-Here is how you might uses `merges` to boost the default font size for
-Android devices:
+While Cordova allows you to easily deploy an app for many different
+platforms, sometimes you need to add customizations.  In that case,
+you don't want to modify the source files in various `www` directories
+within the top-level `platforms` directory, because they're regularly
+replaced with the top-level `www` directory's cross-platform source.
+
+Instead, the top-level `merges` directory offers a place to specify
+assets to deploy on specific platforms. Each platform-specific
+subdirectory within `merges` mirrors the directory structure of the
+`www` source tree, allowing you to override or add files as needed.
+For example, here is how you might uses `merges` to boost the default
+font size for Android devices:
 
 * Edit the `www/index.html` file, adding a link to an additional CSS
   file, `overrides.css` in this case:
 
         <link rel="stylesheet" type="text/css" href="css/overrides.css" />
 
-* Create an empty `www/css/overrides.css` file.
+* Optionally create an empty `www/css/overrides.css` file, which would
+  apply for all non-Android builds, preventing a missing-file error.
 
-* Edit a corresponding `merges/android/overrides.css` file, adding a
-  line that overrides the 12-point default font size specified within
-  `www/css/index.css`:
+* Create a `css` subdirectory within `merges/android`, then add a
+  corresponding `overrides.css` file. Specify CSS that overrides the
+  12-point default font size specified within `www/css/index.css`, for
+  example:
 
         body { font-size:14px; }
 
 When you rebuild the project, the Android version features the custom
 font size, while others remain unchanged.
 
+You can also use `merges` to add files not present in the original
+`www` directory. For example, an app can incorporate a _back button_
+graphic into the iOS interface, stored in
+`merges/ios/img/back_button.png`, while the Android version can
+instead capture `backbutton` events from the corresponding hardware
+button.
+
 ## Update the App
 
 After installing installing the `cordova` utility, you can always