This commit is contained in:
serso
2016-02-24 15:29:42 +01:00
parent b83d5f68e9
commit 828f9fa07b
47 changed files with 2450 additions and 596 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 116 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 188 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 156 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 120 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 219 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 161 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 269 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 223 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 100 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 302 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 276 B

View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.v7.widget.RecyclerView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="match_parent" />

View File

@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="@dimen/list_item_height"
android:background="@drawable/material_clickable_selector"
android:gravity="center_vertical|start"
android:orientation="horizontal"
android:paddingLeft="16dp"
android:paddingRight="16dp"
tools:ignore="Overdraw">
<org.solovyev.android.plotter.PlotIconView
android:id="@+id/function_icon"
android:layout_width="40dp"
android:layout_height="match_parent" />
<TextView
android:id="@+id/fn_name_edittext"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="16dp"
android:layout_marginStart="16dp"
android:drawableEnd="@drawable/ic_mode_edit_white_18dp"
android:drawablePadding="16dp"
android:drawableRight="@drawable/ic_mode_edit_white_18dp" />
</LinearLayout>

View File

@@ -31,51 +31,8 @@
a:layout_height="wrap_content"
a:orientation="vertical">
<android.support.design.widget.TextInputLayout
a:id="@+id/function_name_label"
a:layout_width="match_parent"
a:layout_height="wrap_content">
<EditText
a:id="@+id/function_name"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_name"
a:inputType="text" />
</android.support.design.widget.TextInputLayout>
<org.solovyev.android.calculator.functions.FunctionParamsView
a:id="@+id/function_params"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:orientation="vertical" />
<android.support.design.widget.TextInputLayout
a:id="@+id/function_body_label"
a:layout_width="match_parent"
a:layout_height="wrap_content">
<org.solovyev.android.calculator.view.EditTextCompat
a:id="@+id/function_body"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_value"
a:imeOptions="flagNoExtractUi"
a:inputType="text" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
a:layout_width="match_parent"
a:layout_height="wrap_content">
<EditText
a:id="@+id/function_description"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_description"
a:inputType="textMultiLine"
a:maxLines="4" />
</android.support.design.widget.TextInputLayout>
<include layout="@layout/fragment_function_edit_base_controls" />
</LinearLayout>

View File

@@ -0,0 +1,74 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright 2013 serso aka se.solovyev
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
~
~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~ Contact details
~
~ Email: se.solovyev@gmail.com
~ Site: http://se.solovyev.org
-->
<merge xmlns:a="http://schemas.android.com/apk/res/android">
<android.support.design.widget.TextInputLayout
a:id="@+id/function_name_label"
a:layout_width="match_parent"
a:layout_height="wrap_content">
<EditText
a:id="@+id/function_name"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_name"
a:inputType="text" />
</android.support.design.widget.TextInputLayout>
<org.solovyev.android.calculator.functions.FunctionParamsView
a:id="@+id/function_params"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:orientation="vertical" />
<android.support.design.widget.TextInputLayout
a:id="@+id/function_body_label"
a:layout_width="match_parent"
a:layout_height="wrap_content">
<org.solovyev.android.calculator.view.EditTextCompat
a:id="@+id/function_body"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_value"
a:imeOptions="flagNoExtractUi"
a:inputType="text" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
a:layout_width="match_parent"
a:layout_height="wrap_content">
<EditText
a:id="@+id/function_description"
a:layout_width="match_parent"
a:layout_height="wrap_content"
a:hint="@string/c_function_description"
a:inputType="textMultiLine"
a:maxLines="4" />
</android.support.design.widget.TextInputLayout>
</merge>

View File

@@ -0,0 +1,64 @@
<?xml version="1.0" encoding="utf-8"?>
<org.solovyev.android.plotter.PlotViewFrame xmlns:a="http://schemas.android.com/apk/res/android"
a:id="@id/plot_view_frame"
a:layout_width="match_parent"
a:layout_height="match_parent">
<org.solovyev.android.plotter.PlotView
a:id="@id/plot_view"
a:layout_width="match_parent"
a:layout_height="match_parent" />
<org.solovyev.android.material.MaterialImageButton
a:id="@+id/plot_dimensions"
style="@style/CppPlotButton"
a:layout_gravity="top|start"
a:src="@drawable/ic_straighten_white_24dp" />
<org.solovyev.android.material.MaterialButton
a:id="@id/plot_3d_button"
style="@style/CppPlotButton"
a:layout_gravity="top|end"
a:text="@string/cpp_plot_3d" />
<LinearLayout
a:layout_width="wrap_content"
a:layout_height="wrap_content"
a:layout_gravity="bottom|start"
a:orientation="vertical">
<org.solovyev.android.material.MaterialButton
a:id="@+id/plot_add_function"
style="@style/CppPlotButton"
a:text="@string/cpp_plot_add_function" />
<org.solovyev.android.material.MaterialImageButton
a:id="@+id/plot_functions"
style="@style/CppPlotButton"
a:src="@drawable/ic_list_white_24dp" />
</LinearLayout>
<LinearLayout
a:layout_width="wrap_content"
a:layout_height="wrap_content"
a:layout_gravity="bottom|end"
a:orientation="vertical">
<org.solovyev.android.material.MaterialButton
a:id="@id/plot_zoom_in_button"
style="@style/CppPlotButton"
a:text="@string/cpp_plot_zoom_in" />
<org.solovyev.android.material.MaterialButton
a:id="@id/plot_zoom_reset_button"
style="@style/CppPlotButton"
a:text="@string/cpp_plot_zoom_reset" />
<org.solovyev.android.material.MaterialButton
a:id="@id/plot_zoom_out_button"
style="@style/CppPlotButton"
a:text="@string/cpp_plot_zoom_out" />
</LinearLayout>
</org.solovyev.android.plotter.PlotViewFrame>

View File

@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical">
<LinearLayout
android:id="@+id/x_bounds"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<android.support.design.widget.TextInputLayout
android:id="@+id/plot_x_min_label"
style="@style/DimensionTextInput">
<EditText
android:id="@+id/plot_x_min"
style="@style/DimensionEditText"
android:hint="@string/cpp_dimensions_x_min"
android:nextFocusRight="@+id/plot_x_max" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/plot_x_max_label"
style="@style/DimensionTextInput"
android:layout_marginLeft="@dimen/form_input_margin_hor"
android:layout_marginStart="@dimen/form_input_margin_hor">
<EditText
android:id="@+id/plot_x_max"
style="@style/DimensionEditText"
android:hint="@string/dimensions_x_max"
android:nextFocusDown="@+id/plot_y_min"
android:nextFocusRight="@+id/plot_y_min" />
</android.support.design.widget.TextInputLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/y_bounds"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<android.support.design.widget.TextInputLayout
android:id="@+id/plot_y_min_label"
style="@style/DimensionTextInput">
<EditText
android:id="@+id/plot_y_min"
style="@style/DimensionEditText"
android:hint="@string/dimensions_y_min"
android:nextFocusRight="@+id/plot_y_max" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/plot_y_max_label"
style="@style/DimensionTextInput"
android:layout_marginLeft="@dimen/form_input_margin_hor"
android:layout_marginStart="@dimen/form_input_margin_hor">
<EditText
android:id="@+id/plot_y_max"
style="@style/DimensionEditText.Last"
android:hint="@string/dimensions_y_max" />
</android.support.design.widget.TextInputLayout>
</LinearLayout>
</LinearLayout>

View File

@@ -0,0 +1,90 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright 2013 serso aka se.solovyev
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
~
~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~ Contact details
~
~ Email: se.solovyev@gmail.com
~ Site: http://se.solovyev.org
-->
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
xmlns:app="http://schemas.android.com/apk/res-auto">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<include layout="@layout/fragment_function_edit_base_controls" />
<LinearLayout
android:id="@+id/fn_meshspec_views"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal">
<org.solovyev.android.plotter.PlotIconView
android:id="@+id/fn_iconview"
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_marginEnd="16dp"
android:layout_marginRight="16dp"
android:background="#212121"
android:padding="5dp" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:id="@+id/fn_linewidth_label"
style="@style/TextAppearance.AppCompat.Caption"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/fn_line_width" />
<SeekBar
android:id="@+id/fn_linewidth_seekbar"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<TextView
android:id="@+id/fn_color_label"
style="@style/TextAppearance.AppCompat.Caption"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/fn_line_color" />
<uz.shift.colorpicker.LineColorPicker
android:id="@+id/fn_color_picker"
android:layout_width="match_parent"
android:layout_height="20dp"
app:lcp_orientation="horizontal" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</ScrollView>

View File

@@ -37,12 +37,6 @@
a:title="@string/cpp_plot_3d"
app:showAsAction="ifRoom" />
<item
a:id="@+id/menu_plot_fullscreen"
a:icon="@drawable/ab_expand"
a:title="@string/cpp_fullscreen"
app:showAsAction="ifRoom" />
<item
a:id="@+id/menu_plot_range"
a:icon="@drawable/ab_range"

View File

@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<declare-styleable name="LineColorPicker">
<attr name="lcp_orientation" format="enum">
<enum name="horizontal" value="0" />
<enum name="vertical" value="1" />
</attr>
<attr name="lcp_colors" format="reference" />
<attr name="lcp_selectedColorIndex" format="integer" />
</declare-styleable>
</resources>

View File

@@ -42,4 +42,6 @@
<dimen name="cpp_image_button_padding">5dp</dimen>
<dimen name="cpp_dialog_width_max">400dp</dimen>
<dimen name="cpp_card_margin">4dp</dimen>
<dimen name="list_item_height">48dp</dimen>
</resources>

View File

@@ -167,14 +167,6 @@
<item name="android:orientation">horizontal</item>
</style>
<style name="WizardButton" parent="MaterialButton">
<item name="android:singleLine">true</item>
<item name="android:maxLines">1</item>
<item name="android:lines">1</item>
<item name="android:ellipsize">end</item>
<item name="android:textAppearance">@android:style/TextAppearance.Medium</item>
</style>
<style name="WizardPrimaryButton" parent="PrimaryButton">
<item name="android:singleLine">true</item>
<item name="android:maxLines">1</item>
@@ -202,6 +194,40 @@
<item name="android:textAppearance">@android:style/TextAppearance.Medium</item>
</style>
<style name="CppPlotButton">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:textColor">@color/cpp_button_text</item>
<item name="materialColor">@color/cpp_wizard_button_selector</item>
<item name="android:textAppearance">@android:style/TextAppearance.Medium</item>
<item name="android:minWidth">40dp</item>
<item name="android:minHeight">40dp</item>
</style>
<style name="DimensionEditText.Last" parent="DimensionEditText">
<item name="android:imeOptions">actionDone|flagNoExtractUi</item>
</style>
<style name="DimensionEditText">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:imeOptions">actionNext|flagNoExtractUi</item>
<item name="android:inputType">numberDecimal|numberSigned</item>
<item name="android:selectAllOnFocus">true</item>
<item name="android:gravity">start|center_vertical</item>
</style>
<style name="DimensionTextInput">
<item name="android:layout_width">100dp</item>
<item name="android:layout_height">wrap_content</item>
</style>
<style name="DimensionLabel">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:textAppearance">@android:style/TextAppearance.Medium</item>
</style>
<style name="CppPane.Multipane.Left" parent="CppPane.Multipane">
<item name="android:layout_marginLeft">0dp</item>
</style>

View File

@@ -6,4 +6,12 @@
<string name="cpp_kb_undo" translatable="false"></string>
<string name="cpp_kb_redo" translatable="false"></string>
<string name="cpp_direction_text_size" translatable="false">0.3;0.3;0.3;0.25</string>
<string name="cpp_plot_add_function" translatable="false">+</string>
<string name="cpp_plot_zoom_in" translatable="false">+</string>
<string name="cpp_plot_zoom_reset" translatable="false">0</string>
<string name="cpp_plot_zoom_out" translatable="false"></string>
<string name="cpp_dimensions_x_min" translatable="false">X min</string>
<string name="dimensions_x_max" translatable="false">X max</string>
<string name="dimensions_y_min" translatable="false">Y min</string>
<string name="dimensions_y_max" translatable="false">Y max</string>
</resources>

View File

@@ -239,4 +239,6 @@
<string name="cpp_system_language">System language</string>
<string name="cpp_missing_permission_title">Missing permission</string>
<string name="cpp_missing_permission_msg">Please enable \"%1$s\" permission in system settings</string>
<string name="fn_line_width">Line width</string>
<string name="fn_line_color">Line color</string>
</resources>