Skip to content

Commit 7271050

Browse files
authored
Create master branch via GitHub
1 parent b11cdc7 commit 7271050

File tree

12 files changed

+1615
-0
lines changed

12 files changed

+1615
-0
lines changed

images/body-bg.jpg

2.23 KB
Loading

images/download-button.png

26.5 KB
Loading

images/github-button.png

1.51 KB
Loading

images/header-bg.jpg

9.24 KB
Loading

images/highlight-bg.jpg

30.3 KB
Loading

images/sidebar-bg.jpg

2.22 KB
Loading

index.html

Lines changed: 375 additions & 0 deletions
Large diffs are not rendered by default.

javascripts/main.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
console.log('This would be the main JS file.');

params.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"name": "Materialdesignlibrary",
3+
"tagline": "This is a library with components of Android L to you use in android 2.2",
4+
"body": "![Material design library logo](images/logo.png)\r\n\r\n# Material Design Android Library\r\n\r\n<a href=\"https://play.google.com/store/apps/details?id=com.gc.demomaterialdesign\">\r\n <img alt=\"Android app on Google Play\" src=\"https://developer.android.com/images/brand/en_app_rgb_wo_45.png\" />\r\n</a>\r\n\r\n\r\n[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-Material%20Design%20Android%20Library-brightgreen.svg?style=flat)](https://android-arsenal.com/details/1/1156)\r\n\r\n* [How to use](#howtouse)\r\n* [Components](#components)\r\n * [Buttons](#buttons)\r\n * [Flat Button](#flat-button)\r\n * [Rectangle Button](#rectangle-button)\r\n * [Float Button](#float-button)\r\n * [Float small button](#float-small-button)\r\n * [Switches](#switches)\r\n * [CheckBox](#checkbox)\r\n * [Switch](#switch)\r\n * [Progress indicators](#progress-indicators)\r\n * [Progress bar circular indeterminate](#progress-bar-circula-rindeterminate)\r\n * [Progress bar indeterminate](#progress-bar-indeterminate)\r\n * [Progress bar indeterminate determinate](#progress-bar-indeterminate-determinate)\r\n * [Progress bar determinate](#progress-bar-determinate)\r\n * [Slider](#slider)\r\n * [Slider with number indicator](#slider-with-number-indicator)\r\n* [Widgets](#widgets)\r\n * [SnackBar](#snackbar)\r\n * [Dialog](#dialog)\r\n * [Color selector](#color-selector)\r\n\r\n## How to use\r\n\r\nIf you want use this library, you only have to download MaterialDesign project, import it into your workspace and add the project as a library in your android project settings.\r\n\r\nIf you prefer it, you can use the gradle dependency, you have to add these lines in your build.gradle file:\r\n\r\n```xml\r\nrepositories {\r\n jcenter()\r\n}\r\n\r\ndependencies {\r\n compile 'com.github.navasmdc:MaterialDesign:1.5@aar'\r\n}\r\n```\r\n\r\nSome components have custom attributes, if you want use them, you must add this line in your xml file in the first component:\r\n\r\n```xml\r\n<RelativeLayout xmlns:android=\"http://schemas.android.com/apk/res/android\"\r\n xmlns:materialdesign=\"http://schemas.android.com/apk/res-auto\"\r\n android:layout_width=\"match_parent\"\r\n android:layout_height=\"match_parent\"\r\n >\r\n</RelativeLayout>\r\n```\r\n\r\n>If you are going to use a ScrollView, it is recommended that you use the CustomScrollView provided in this library to avoid problems with the custom components.\r\n>To use this component:\r\n>```xml\r\n><com.gc.materialdesign.views.ScrollView \r\n> xmlns:android=\"http://schemas.android.com/apk/res/android\"\r\n> xmlns:materialdesign=\"http://schemas.android.com/apk/res-auto\"\r\n> android:id=\"@+id/scroll\"\r\n> android:layout_width=\"match_parent\"\r\n> android:layout_height=\"match_parent\">\r\n></com.gc.materialdesign.views.ScrollView>\r\n>```\r\n\r\n##Components\r\n\r\n####Buttons\r\n\r\n######Flat Button\r\n\r\n![flat button](images/flat_button.png)\r\n```xml\r\n<com.gc.materialdesign.views.ButtonFlat\r\n android:id=\"@+id/buttonflat\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n android:text=\"Button\" />\r\n```\r\n\r\n######Rectangle Button\r\n\r\n![rectangle button](images/rectangle_button.png)\r\n```xml\r\n<com.gc.materialdesign.views.ButtonRectangle\r\n android:id=\"@+id/button\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n android:text=\"Button\" />\r\n```\r\n\r\n######Float Button\r\n\r\n![float button](images/float_button.png)\r\n\r\n>It is recommended to put this component in the right-bottom of the screen. To use this component write this code in your xml file.\r\n>If you don`t want to start this component with animation set the animate attribute to false.\r\n>Put your icon in the icon attribute to set the drawable icon for this component.\r\n\r\n```xml\r\n<RelativeLayout xmlns:android=\"http://schemas.android.com/apk/res/android\"\r\n xmlns:materialdesign=\"http://schemas.android.com/apk/res-auto\"\r\n android:layout_width=\"match_parent\"\r\n android:layout_height=\"match_parent\"\r\n >\r\n <!-- ... XML CODE -->\r\n <com.gc.materialdesign.views.ButtonFloat\r\n android:id=\"@+id/buttonFloat\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:layout_alignParentRight=\"true\"\r\n android:layout_alignParentBottom=\"true\"\r\n android:layout_marginRight=\"24dp\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:animate=\"true\"\r\n materialdesign:iconDrawable=\"@drawable/ic_action_new\" />\r\n</RelativeLayout>\r\n```\r\n\r\n######Float small button\r\n\r\n![float small button](images/float_small_button.png)\r\n\r\n```xml\r\n<com.gc.materialdesign.views.ButtonFloatSmall\r\n android:id=\"@+id/buttonFloatSmall\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:iconDrawable=\"@drawable/ic_action_new\" />\r\n```\r\n\r\n####Switches\r\n\r\n######CheckBox\r\n![checkbox](images/checkbox.png)\r\n\r\n```xml\r\n<com.gc.materialdesign.views.CheckBox\r\n android:id=\"@+id/checkBox\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:check=\"true\" />\r\n```\r\n\r\n######Switch\r\n![switch](images/switch.png)\r\n\r\n```xml\r\n<com.gc.materialdesign.views.Switch\r\n android:id=\"@+id/switchView\"\r\n android:layout_width=\"wrap_content\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:check=\"true\" />\r\n```\r\n\r\n####Progress indicators\r\n\r\n######Progress bar circular indeterminate\r\n![progress bar circular indeterminate](images/progress_bar_circular_indeterminate.png)\r\n\r\n```xml\r\n<com.gc.materialdesign.views.ProgressBarCircularIndeterminate\r\n android:id=\"@+id/progressBarCircularIndeterminate\"\r\n android:layout_width=\"32dp\"\r\n android:layout_height=\"32dp\"\r\n android:background=\"#1E88E5\" />\r\n```\r\n\r\n######Progress bar indeterminate\r\n![progress bar indeterminate](images/progress_bar_indeterminate.png)\r\n\r\n```xml\r\n<com.gc.materialdesign.views.ProgressBarIndeterminate\r\n android:id=\"@+id/progressBarIndeterminate\"\r\n android:layout_width=\"fill_parent\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\" />\r\n```\r\n\r\n######Progress bar indeterminate determinate\r\n![Progress bar indeterminate determinate](images/progress_bar_indeterminate_determinate.png)\r\n\r\n\r\n```xml\r\n<com.gc.materialdesign.views.ProgressBarIndeterminateDeterminate\r\n android:id=\"@+id/progressBarIndeterminateDeterminate\"\r\n android:layout_width=\"fill_parent\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\" />\r\n```\r\n\r\n>If you begin progrees, you only have to set progress it\r\n>\r\n>```java\r\n>progressBarIndeterminateDeterminate.setProgress(progress);\r\n>```\r\n\r\n######Progress bar determinate\r\n![Progress bar determinate](images/progress_bar_determinate.png)\r\n\r\n\r\n```xml\r\n<com.gc.materialdesign.views.ProgressBarDeterminate\r\n android:id=\"@+id/progressDeterminate\"\r\n android:layout_width=\"fill_parent\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\" />\r\n```\r\n\r\n>You can custom max and min progress values with `materialdesign:max=\"50\"` and `materialdesign:min=\"25\"` attributes.\r\n\r\n######Slider\r\n![Slider](images/slider.png)\r\n\r\n\r\n```xml\r\n<com.gc.materialdesign.views.Slider\r\n android:id=\"@+id/slider\"\r\n android:layout_width=\"fill_parent\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:max=\"50\"\r\n materialdesign:min=\"0\"\r\n />\r\n```\r\n\r\n######Slider with number indicator\r\n![Slider with number indicator](images/slider_with_number_indicator.png)\r\n\r\n\r\n```xml\r\n<com.gc.materialdesign.views.Slider\r\n android:id=\"@+id/slider\"\r\n android:layout_width=\"fill_parent\"\r\n android:layout_height=\"wrap_content\"\r\n android:background=\"#1E88E5\"\r\n materialdesign:max=\"50\"\r\n materialdesign:min=\"0\"\r\n materialdesign:showNumberIndicator=\"true\"/>\r\n```\r\n\r\n##Widgets\r\n\r\n####SnackBar\r\n\r\n![Snackbar](images/snackbar.png)\r\n\r\n\r\n```java\r\nSnackBar snackbar = new SnackBar(Activity activity, String text, String buttonText, View.OnClickListener onClickListener);\r\nsnackbar.show();\r\n```\r\n\r\n> If you don't want to show the button, put `null` in `buttonText` attribute\r\n\r\n####Dialog\r\n\r\n![Dialog](images/dialog.png)\r\n\r\n```java\r\nDialog dialog = new Dialog(Context context,String title, String message);\r\ndialog.show();\r\n```\r\n\r\n>You can set the accept and cancel button on the event listener or change it's text\r\n>```java\r\n> // Set accept click listenner\r\n>dialog.setOnAcceptButtonClickListener(View.OnClickListener onAcceptButtonClickListener);\r\n> // Set cancel click listenner\r\n>dialog.setOnCancelButtonClickListener(View.OnClickListener onCancelButtonClickListener);\r\n> // Acces to accept button\r\n>ButtonFlat acceptButton = dialog.getButtonAccept();\r\n> // Acces to cancel button\r\n>ButtonFlat cancelButton = dialog.getButtonCancel();\r\n>```\r\n\r\n####Color selector\r\n\r\n![Color selector](images/color_selector.png)\r\n\r\n```java\r\nColorSelector colorSelector = new ColorSelector(Context context,int intialColor, OnColorSelectedListener onColorSelectedListener);\r\ncolorSelector.show();\r\n```\r\n\r\n\r\n\r\n\r\n\r\n",
5+
"note": "Don't delete this file! It's used internally to help with page regeneration."
6+
}

stylesheets/github-light.css

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
/*
2+
The MIT License (MIT)
3+
4+
Copyright (c) 2016 GitHub, Inc.
5+
6+
Permission is hereby granted, free of charge, to any person obtaining a copy
7+
of this software and associated documentation files (the "Software"), to deal
8+
in the Software without restriction, including without limitation the rights
9+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10+
copies of the Software, and to permit persons to whom the Software is
11+
furnished to do so, subject to the following conditions:
12+
13+
The above copyright notice and this permission notice shall be included in all
14+
copies or substantial portions of the Software.
15+
16+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22+
SOFTWARE.
23+
24+
*/
25+
26+
.pl-c /* comment */ {
27+
color: #969896;
28+
}
29+
30+
.pl-c1 /* constant, variable.other.constant, support, meta.property-name, support.constant, support.variable, meta.module-reference, markup.raw, meta.diff.header */,
31+
.pl-s .pl-v /* string variable */ {
32+
color: #0086b3;
33+
}
34+
35+
.pl-e /* entity */,
36+
.pl-en /* entity.name */ {
37+
color: #795da3;
38+
}
39+
40+
.pl-smi /* variable.parameter.function, storage.modifier.package, storage.modifier.import, storage.type.java, variable.other */,
41+
.pl-s .pl-s1 /* string source */ {
42+
color: #333;
43+
}
44+
45+
.pl-ent /* entity.name.tag */ {
46+
color: #63a35c;
47+
}
48+
49+
.pl-k /* keyword, storage, storage.type */ {
50+
color: #a71d5d;
51+
}
52+
53+
.pl-s /* string */,
54+
.pl-pds /* punctuation.definition.string, string.regexp.character-class */,
55+
.pl-s .pl-pse .pl-s1 /* string punctuation.section.embedded source */,
56+
.pl-sr /* string.regexp */,
57+
.pl-sr .pl-cce /* string.regexp constant.character.escape */,
58+
.pl-sr .pl-sre /* string.regexp source.ruby.embedded */,
59+
.pl-sr .pl-sra /* string.regexp string.regexp.arbitrary-repitition */ {
60+
color: #183691;
61+
}
62+
63+
.pl-v /* variable */ {
64+
color: #ed6a43;
65+
}
66+
67+
.pl-id /* invalid.deprecated */ {
68+
color: #b52a1d;
69+
}
70+
71+
.pl-ii /* invalid.illegal */ {
72+
color: #f8f8f8;
73+
background-color: #b52a1d;
74+
}
75+
76+
.pl-sr .pl-cce /* string.regexp constant.character.escape */ {
77+
font-weight: bold;
78+
color: #63a35c;
79+
}
80+
81+
.pl-ml /* markup.list */ {
82+
color: #693a17;
83+
}
84+
85+
.pl-mh /* markup.heading */,
86+
.pl-mh .pl-en /* markup.heading entity.name */,
87+
.pl-ms /* meta.separator */ {
88+
font-weight: bold;
89+
color: #1d3e81;
90+
}
91+
92+
.pl-mq /* markup.quote */ {
93+
color: #008080;
94+
}
95+
96+
.pl-mi /* markup.italic */ {
97+
font-style: italic;
98+
color: #333;
99+
}
100+
101+
.pl-mb /* markup.bold */ {
102+
font-weight: bold;
103+
color: #333;
104+
}
105+
106+
.pl-md /* markup.deleted, meta.diff.header.from-file */ {
107+
color: #bd2c00;
108+
background-color: #ffecec;
109+
}
110+
111+
.pl-mi1 /* markup.inserted, meta.diff.header.to-file */ {
112+
color: #55a532;
113+
background-color: #eaffea;
114+
}
115+
116+
.pl-mdr /* meta.diff.range */ {
117+
font-weight: bold;
118+
color: #795da3;
119+
}
120+
121+
.pl-mo /* meta.output */ {
122+
color: #1d3e81;
123+
}
124+

stylesheets/print.css

Lines changed: 228 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,228 @@
1+
html, body, div, span, applet, object, iframe,
2+
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
3+
a, abbr, acronym, address, big, cite, code,
4+
del, dfn, em, img, ins, kbd, q, s, samp,
5+
small, strike, strong, sub, sup, tt, var,
6+
b, u, i, center,
7+
dl, dt, dd, ol, ul, li,
8+
fieldset, form, label, legend,
9+
table, caption, tbody, tfoot, thead, tr, th, td,
10+
article, aside, canvas, details, embed,
11+
figure, figcaption, footer, header, hgroup,
12+
menu, nav, output, ruby, section, summary,
13+
time, mark, audio, video {
14+
padding: 0;
15+
margin: 0;
16+
font: inherit;
17+
font-size: 100%;
18+
vertical-align: baseline;
19+
border: 0;
20+
}
21+
/* HTML5 display-role reset for older browsers */
22+
article, aside, details, figcaption, figure,
23+
footer, header, hgroup, menu, nav, section {
24+
display: block;
25+
}
26+
body {
27+
line-height: 1;
28+
}
29+
ol, ul {
30+
list-style: none;
31+
}
32+
blockquote, q {
33+
quotes: none;
34+
}
35+
blockquote:before, blockquote:after,
36+
q:before, q:after {
37+
content: '';
38+
content: none;
39+
}
40+
table {
41+
border-spacing: 0;
42+
border-collapse: collapse;
43+
}
44+
body {
45+
font-family: 'Helvetica Neue', Helvetica, Arial, serif;
46+
font-size: 13px;
47+
line-height: 1.5;
48+
color: #000;
49+
}
50+
51+
a {
52+
font-weight: bold;
53+
color: #d5000d;
54+
}
55+
56+
header {
57+
padding-top: 35px;
58+
padding-bottom: 10px;
59+
}
60+
61+
header h1 {
62+
font-size: 48px;
63+
font-weight: bold;
64+
line-height: 1.2;
65+
color: #303030;
66+
letter-spacing: -1px;
67+
}
68+
69+
header h2 {
70+
font-size: 24px;
71+
font-weight: normal;
72+
line-height: 1.3;
73+
color: #aaa;
74+
letter-spacing: -1px;
75+
}
76+
#downloads {
77+
display: none;
78+
}
79+
#main_content {
80+
padding-top: 20px;
81+
}
82+
83+
code, pre {
84+
margin-bottom: 30px;
85+
font-family: Monaco, "Bitstream Vera Sans Mono", "Lucida Console", Terminal;
86+
font-size: 12px;
87+
color: #222;
88+
}
89+
90+
code {
91+
padding: 0 3px;
92+
}
93+
94+
pre {
95+
padding: 20px;
96+
overflow: auto;
97+
border: solid 1px #ddd;
98+
}
99+
pre code {
100+
padding: 0;
101+
}
102+
103+
ul, ol, dl {
104+
margin-bottom: 20px;
105+
}
106+
107+
108+
/* COMMON STYLES */
109+
110+
table {
111+
width: 100%;
112+
border: 1px solid #ebebeb;
113+
}
114+
115+
th {
116+
font-weight: 500;
117+
}
118+
119+
td {
120+
font-weight: 300;
121+
text-align: center;
122+
border: 1px solid #ebebeb;
123+
}
124+
125+
form {
126+
padding: 20px;
127+
background: #f2f2f2;
128+
129+
}
130+
131+
132+
/* GENERAL ELEMENT TYPE STYLES */
133+
134+
h1 {
135+
font-size: 2.8em;
136+
}
137+
138+
h2 {
139+
margin-bottom: 8px;
140+
font-size: 22px;
141+
font-weight: bold;
142+
color: #303030;
143+
}
144+
145+
h3 {
146+
margin-bottom: 8px;
147+
font-size: 18px;
148+
font-weight: bold;
149+
color: #d5000d;
150+
}
151+
152+
h4 {
153+
font-size: 16px;
154+
font-weight: bold;
155+
color: #303030;
156+
}
157+
158+
h5 {
159+
font-size: 1em;
160+
color: #303030;
161+
}
162+
163+
h6 {
164+
font-size: .8em;
165+
color: #303030;
166+
}
167+
168+
p {
169+
margin-bottom: 20px;
170+
font-weight: 300;
171+
}
172+
173+
a {
174+
text-decoration: none;
175+
}
176+
177+
p a {
178+
font-weight: 400;
179+
}
180+
181+
blockquote {
182+
padding: 0 0 0 30px;
183+
margin-bottom: 20px;
184+
font-size: 1.6em;
185+
border-left: 10px solid #e9e9e9;
186+
}
187+
188+
ul li {
189+
padding-left: 20px;
190+
list-style-position: inside;
191+
list-style: disc;
192+
}
193+
194+
ol li {
195+
padding-left: 3px;
196+
list-style-position: inside;
197+
list-style: decimal;
198+
}
199+
200+
dl dd {
201+
font-style: italic;
202+
font-weight: 100;
203+
}
204+
205+
footer {
206+
padding-top: 20px;
207+
padding-bottom: 30px;
208+
margin-top: 40px;
209+
font-size: 13px;
210+
color: #aaa;
211+
}
212+
213+
footer a {
214+
color: #666;
215+
}
216+
217+
/* MISC */
218+
.clearfix:after {
219+
display: block;
220+
height: 0;
221+
clear: both;
222+
visibility: hidden;
223+
content: '.';
224+
}
225+
226+
.clearfix {display: inline-block;}
227+
* html .clearfix {height: 1%;}
228+
.clearfix {display: block;}

0 commit comments

Comments
 (0)