Git Product home page Git Product logo

androidmath's People

Contributors

gregcockroft avatar oskarpersson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

androidmath's Issues

findview

I cant use findviewById in java...
this library is just for kotlin?
help me plaese I am java develooper .
thanks.

Text alignment issue.

I am using the component TextViewJustify class. to this class i am setting the text "A motorist traveling to thiruvananthapuram at 10m/s can bring his car to rest in a distance of 10 m."
I am using android:justificationMode="inter_word"

actual:
"A motorist traveling to thiruvananthapuram at 10m/
s can bring his car to rest in a distance of 10 m."

expectation is:
"A motorist traveling to thiruvananthapuram at 10m/s
can bring his car to rest in a distance of 10 m."

latex

mathview = findviewbyid.............
mathview.latex = "x = \frac{-b \pm \sqrt{b^2-4ac}}{2a}"
"latex" showing red ... seems no latex attribute there. how to solv this?

How to get actual render size?

Is it possible to get the bounding box of the actual rendered content, meaning the height and the width from the canvas?

Rendering issue on some devices

I got some rendering issue on some devices. It is not rendering at all on some devices when I install a debug APK. (Image A) When I create a release APK, it renders overlapped. It's unreadable (Image B). But some devices same project working properly. (Image C)

I tried it on more than 10 devices (deferent OS, deferent model) manually and on half of them not working properly. Also I observed that same device (model) has working and not-working issue.

Any help ?

Thanks !
Hashan.

Image A - DEBUG MODE PREVIEW (not rendering) :
issue_debug_mode
Image B - RELEASE MODE PREVIEW (overlapped) :
issue_release_mode

Image C - WORKING PROPERLY :
working_properly_x

(Image A and B on same device (Samsung Galaxy A01) C on Samsung Galaxy A50)

java.lang.reflect.invocationtargetexception

Getting target exception in the XML mentioning library <com.agog.mathdisplay.MTMathView when compileSdkVersion and targetSdkVersion increasing to 30 and 31 may be in jcenter and maven { url "https://jitpack.io" } is deprecated in api level 30 and 31. Dependency is not working increasing api level please take it as a priority and fix the issue.

Delta F -> F is not printing properly.

'\text{Slope of line }\mathrm{AB}=\frac{\Delta{C}}{\Delta{F}}

\\=\frac{100-0}{212-32}=\frac{100}{180}=\frac{5}{9}
'

if we added the extra space after the Delta{F}} its working fine. Please refer the below letax. our expectation should work with above formula.. Please refer below screenshot. which is highlighted because u can understand the whitespace.
  '\text{Slope of line }\mathrm{AB}=\frac{\Delta{C}}{\Delta{F}} 

\\=\frac{100-0}{212-32}=\frac{100}{180}=\frac{5}{9}
'

Screenshot (31)

Adapt library for AndroidX

When building this library in modern AndroidX environment, there are dependency resolution errors, as such:

Duplicate class android.support.v4.app.INotificationSideChannel found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.app.INotificationSideChannel$Stub$Proxy found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver$Stub found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.IResultReceiver$Stub$Proxy found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$1 found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$MyResultReceiver found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)
Duplicate class android.support.v4.os.ResultReceiver$MyRunnable found in modules core-1.6.0-runtime (androidx.core:core:1.6.0) and support-compat-27.1.1-runtime (com.android.support:support-compat:27.1.1)

There is a way to fix it by enabling jettifier. It would be much better if these issues were fixed at the library level. @gregcockroft, please consider adapting your very helpful library to AndroidX.

java.lang.reflect.InvocationTargetException in Android 11 Version mobile Caused by: com.agog.mathdisplay.parse.MathDisplayException: Error initializing FreeType.

When i am trying to update TargetSDKversion to "30" In MXL File getting error inflating class please look into it below log files. it is not working only in android 11 version mobile.

android.view.InflateException: Binary XML file line #88 in com.iguru.school.leadindiabharat:layout/item_queastionlist: Binary XML file line #88 in com.iguru.school.leadindiabharat:layout/item_queastionlist: Error inflating class com.agog.mathdisplay.MTMathView
Caused by: android.view.InflateException: Binary XML file line #88 in com.iguru.school.leadindiabharat:layout/item_queastionlist: Error inflating class com.agog.mathdisplay.MTMathView
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.newInstance0(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
at android.view.LayoutInflater.createView(LayoutInflater.java:852)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:1004)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:959)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1121)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:1124)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:1082)
at android.view.LayoutInflater.inflate(LayoutInflater.java:680)
at android.view.LayoutInflater.inflate(LayoutInflater.java:532)
at com.iguru.school.leadindiabharat.elearning.QuestionsAdpter.onCreateViewHolder(QuestionsAdpter.java:116)
at com.iguru.school.leadindiabharat.elearning.QuestionsAdpter.onCreateViewHolder(QuestionsAdpter.java:44)
at androidx.recyclerview.widget.RecyclerView$Adapter.createViewHolder(RecyclerView.java:7295)
at androidx.recyclerview.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:6416)
at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:6300)
at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:6296)
at androidx.recyclerview.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:2330)
at androidx.recyclerview.widget.LinearLayoutManager.layoutChunk(LinearLayoutManager.java:1631)
at androidx.recyclerview.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1591)
at androidx.recyclerview.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:668)
at androidx.recyclerview.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:4309)
at androidx.recyclerview.widget.RecyclerView.dispatchLayout(RecyclerView.java:4012)
at androidx.recyclerview.widget.RecyclerView.onLayout(RecyclerView.java:4578)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1829)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1673)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1582)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.FrameLayout.layoutChildren(FrameLayout.java:332)
at android.widget.FrameLayout.onLayout(FrameLayout.java:270)
2021-10-27 10:45:17.705 19213-19213/com.iguru.school.leadindiabharat E/AndroidRuntime: at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.FrameLayout.layoutChildren(FrameLayout.java:332)
at android.widget.FrameLayout.onLayout(FrameLayout.java:270)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.FrameLayout.layoutChildren(FrameLayout.java:332)
at android.widget.FrameLayout.onLayout(FrameLayout.java:270)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1829)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1673)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1582)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.FrameLayout.layoutChildren(FrameLayout.java:332)
at android.widget.FrameLayout.onLayout(FrameLayout.java:270)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1829)
at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1673)
at android.widget.LinearLayout.onLayout(LinearLayout.java:1582)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.widget.FrameLayout.layoutChildren(FrameLayout.java:332)
at android.widget.FrameLayout.onLayout(FrameLayout.java:270)
at com.android.internal.policy.DecorView.onLayout(DecorView.java:1225)
at android.view.View.layout(View.java:24475)
at android.view.ViewGroup.layout(ViewGroup.java:7383)
at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:4260)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:3695)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:2618)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:9971)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1010)
at android.view.Choreographer.doCallbacks(Choreographer.java:809)
at android.view.Choreographer.doFrame(Choreographer.java:744)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:995)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:246)
at android.app.ActivityThread.main(ActivityThread.java:8595)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
Caused by: com.agog.mathdisplay.parse.MathDisplayException: Error initializing FreeType.
at com.agog.mathdisplay.render.MTFontMathTable.(MTFontMathTable.kt:94)
at com.agog.mathdisplay.render.MTFont.(MTFont.kt:19)
at com.agog.mathdisplay.render.MTFont.(MTFont.kt:9)
at com.agog.mathdisplay.MTFontManager$Companion.fontWithName(MTFontManager.kt:25)
at com.agog.mathdisplay.MTFontManager$Companion.latinModernFontWithSize(MTFontManager.kt:42)
at com.agog.mathdisplay.MTFontManager$Companion.defaultFont(MTFontManager.kt:54)
at com.agog.mathdisplay.MTMathView.(MTMathView.kt:126)
at com.agog.mathdisplay.MTMathView.(MTMathView.kt:32)
at com.agog.mathdisplay.MTMathView.(Unknown Source:6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.