This is a simple patternview-class. I have tested it on my iPhone6+ without problems. Feel free to use or improve it.
The result of the pattern in the showpattern-event is related to https://www.b4x.com/android/forum/threads/patternview.67838/#content
The result of the pattern in the showpattern-event is related to https://www.b4x.com/android/forum/threads/patternview.67838/#content
B4X:
Sub Process_Globals
Public App As Application
Public NavControl As NavigationController
Public Page1 As Page
Public Patternview As clsPatternview
Private Panel1 As Panel
End Sub
Private Sub Application_Start (Nav As NavigationController)
NavControl = Nav
Page1.Initialize("Page1")
Page1.RootPanel.Color=Colors.White
Panel1.Initialize("")
Page1.RootPanel.AddView(Panel1, 0,0,400dip, 400dip)
NavControl.ShowPage(Page1)
'PatternView.Initialize(EventName As String, p As Panel, GridSize As Int, DotColor As Int, LineColor As Int, StrokeWith As Int)
Patternview.Initialize("Patternview", Panel1, 5, Colors.Black, Colors.red, 5)
End Sub
Sub Patternview_showpattern(Code As String)
Msgbox(Code, "")
End Sub