Skip to content
This repository was archived by the owner on May 15, 2025. It is now read-only.

Commit 8e6e4e4

Browse files
agaldanaw2agaldanawAgustinBonilla
authored
material slider control (#25)
* initial commit test slider * faltan ejemplos * title page * save * falta documentación, imágenes fondo * add images * new examples * readme * Apply improvements Co-authored-by: AndresAldana <agaldanaw@unal.edu.co> Co-authored-by: Agustin Bonilla <agustin.bonilla@horus.com.uy>
1 parent 5487cd8 commit 8e6e4e4

33 files changed

Lines changed: 1376 additions & 45 deletions

MaterialSliderControl.md

Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
# MaterialSliderControl
2+
This control is a custom implementation of a slider. You can customize some properties that we show in Documentation topic.
3+
4+
## Screenshot
5+
<img src="https://github.com/HorusSoftwareUY/MaterialDesignControlsPlugin/blob/master/screenshots/material_slider.jpg" width="300">
6+
7+
## how use?
8+
```XML
9+
<material:MaterialSlider
10+
x:Name="slider"
11+
MinimumValue="0"
12+
MaximumValue="100"
13+
ThumbColor="BlueViolet"
14+
LabelText="Slider"
15+
ActiveTrackColor="BlueViolet"
16+
InactiveTrackColor="LightPink"/>
17+
```
18+
19+
## Documentation
20+
21+
### Property ValueChanged
22+
This property is to add an event when the value change on the control
23+
24+
### Property LabelText:
25+
This property is to set the label text value
26+
27+
### Property LabelTextColor:
28+
This property is to set the color of the label text when the control is enabled
29+
30+
### Property DisabledLabelTextColor:
31+
This property is to set the color of the label text when the control is disabled
32+
33+
### Property LabelSize:
34+
This property is to set the fontsize of the label text
35+
36+
### Property LabelMinimumText:
37+
This property is to set the label minimum value
38+
39+
### Property LabelMinimumTextColor:
40+
This property is to set the color of the label minimum when control is enabled
41+
42+
### Property DisabledLabelMinimumTextColor:
43+
This property is to set the color of the label minimum when control is disable
44+
45+
### Property LabelMinimumSize:
46+
This property is to set the font size of the label minimum
47+
48+
### Property LabelMaximumText:
49+
This property is to set the label maximum text value on the control.
50+
51+
### Property LabelMaximumTextColor:
52+
This property is to set the label maximum text color value on the control enabled
53+
54+
### Property DisabledLabelMaximumTextColor:
55+
This property is to set the label text maximum color value on the control. when the control is disabled
56+
57+
### Property AssistiveText:
58+
This property is to set the error text on the control.
59+
60+
### Property AssistiveTextColor:
61+
This property is to set the error text color value on the control. By default is gray.
62+
63+
### Property AssistiveSize:
64+
This property is to set the error text font size value on the control. By default is gray.
65+
66+
### Property AnimateError:
67+
This property is to set if you can show a ShakeAnimation when there is a error with control.
68+
69+
### Property MinimumIcon:
70+
This property is to set the image to minimum to types of images like png, jpg.
71+
72+
### Property CustomMinimumIcon:
73+
This property is to set the image to minimum with support to svg.
74+
75+
### Property MaximumIcon:
76+
This property is to set the image to maximum to types of images like png, jpg.
77+
78+
### Property CustomMaximumIcon:
79+
This property is to set the image to maximum with support to svg.
80+
81+
### Property BackgroundImage:
82+
This property is to set the background image to control, this allow jpg, png.
83+
84+
### Property CustomBackgroundImage:
85+
This property is to set the background image to control, this allow svg.
86+
87+
### Property ThumbImage:
88+
This property is to set the thumb with a image.
89+
90+
### Property Value:
91+
This property is to set the value of the control, by default is the minimum.
92+
93+
### Property MinimumValue:
94+
This property is to set the minimum value, by default is 0.
95+
96+
### Property MaximumValue:
97+
This property is to set the minimum value, by default is 1.
98+
99+
### Property ActiveTrackColor:
100+
This property is to set the active tracker color
101+
102+
### Property InactiveTrackColor:
103+
This property is to set the inactive tracker color.
104+
105+
### Property ThumbColor:
106+
This property is to set the color of thumb
107+
108+
### Property TrackHeight:
109+
This property is to set the height of the thumb
110+
111+
### Property TrackCornerRadius:
112+
This property is to set the corner radious of the track
113+
114+
### Property UserInteractionEnabled:
115+
This property is to set the if the interaction of the user is enabled
116+
117+
### Property ShowIcons:
118+
This property is to set if show or not the icons.
119+
120+
### Property DisabledActiveTrackColor:
121+
This property is to set the disabled active track color, when the control is disabled.
122+
123+
### Property DisabledInactiveTrackColor:
124+
This property is to set the disabled inactive track color, when the control is disabled.
125+
126+
### Property DisabledThumbColor:
127+
This property is to set the disabled thumb color, whe the control is disabled.
128+
129+
130+
131+
132+
133+
134+
135+
136+
137+

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,27 @@ Selection let users select an option.
163163
Command="{Binding TapCommand}" CommandParameter="User selection" />
164164
```
165165

166+
167+
### MaterialSliderControl
168+
Displays a slider control<br/>
169+
[View documentation](MaterialSliderControl.md)
170+
171+
**Screenshot**
172+
173+
<img src="https://github.com/HorusSoftwareUY/MaterialDesignControlsPlugin/blob/master/screenshots/material_slider.jpg" width="300">
174+
175+
**Example**
176+
```XML
177+
<material:MaterialSlider
178+
x:Name="slider"
179+
MinimumValue="0"
180+
MaximumValue="100"
181+
ThumbColor="BlueViolet"
182+
LabelText="Slider"
183+
ActiveTrackColor="BlueViolet"
184+
InactiveTrackColor="LightPink"/>
185+
```
186+
166187
### MaterialField
167188
Displays a value with its respective label in read-only format.
168189

example/ExampleMaterialDesignControls.Android/ExampleMaterialDesignControls.Android.csproj

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?xml version="1.0" encoding="utf-8"?>
1+
<?xml version="1.0" encoding="utf-8"?>
22
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
@@ -107,12 +107,10 @@
107107
<AndroidResource Include="Resources\drawable\showPassword.png" />
108108
</ItemGroup>
109109
<ItemGroup>
110-
<Folder Include="Resources\drawable\" />
111110
<Folder Include="Resources\drawable-hdpi\" />
112111
<Folder Include="Resources\drawable-xhdpi\" />
113112
<Folder Include="Resources\drawable-xxhdpi\" />
114113
<Folder Include="Resources\drawable-xxxhdpi\" />
115-
<Folder Include="Assets\Fonts\" />
116114
</ItemGroup>
117115
<ItemGroup>
118116
<ProjectReference Include="..\ExampleMaterialDesignControls\ExampleMaterialDesignControls.csproj">
@@ -142,5 +140,14 @@
142140
<Link>Assets\Fonts\font_bold.ttf</Link>
143141
</AndroidAsset>
144142
</ItemGroup>
145-
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
146-
</Project>
143+
<ItemGroup>
144+
<AndroidResource Include="Resources\drawable\volume.png" />
145+
</ItemGroup>
146+
<ItemGroup>
147+
<AndroidResource Include="Resources\drawable\mute.png" />
148+
</ItemGroup>
149+
<ItemGroup>
150+
<AndroidResource Include="Resources\drawable\scale.png" />
151+
</ItemGroup>
152+
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
153+
</Project>

example/ExampleMaterialDesignControls.Android/Resources/Resource.designer.cs

Lines changed: 26 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
7.81 KB
Loading
5.66 KB
Loading
14.4 KB
Loading

example/ExampleMaterialDesignControls.iOS/ExampleMaterialDesignControls.iOS.csproj

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,4 +210,13 @@
210210
<Link>Resources\Fonts\font_semi_bold.ttf</Link>
211211
</BundleResource>
212212
</ItemGroup>
213+
<ItemGroup>
214+
<BundleResource Include="Resources\volume.png" />
215+
</ItemGroup>
216+
<ItemGroup>
217+
<BundleResource Include="Resources\mute.png" />
218+
</ItemGroup>
219+
<ItemGroup>
220+
<BundleResource Include="Resources\scale.png" />
221+
</ItemGroup>
213222
</Project>
7.81 KB
Loading
5.66 KB
Loading

0 commit comments

Comments
 (0)