Forum Replies Created
-
AuthorPosts
-
any thoughts on giving more highlighting some time ? I cant stress just how important it is for people like me, matching Jungle’s options would be nice but in a pinch I would love to be able to have a specific colour for the following..
yes, about $50.
is there a reason for the mouse cursor not switching to IBeam at CodeTextView EventType.MouseEnter?
And then back to Arrow on CodeTextView EventType.MouseLeave.I like it too, will try.
Oh and if you switch to the ‘AutoComplete’ tab in ‘Preferences’, then close and open it again, then go to the IRC tab, there are ugly scrollbars.
oh.
Got it. What ‘modifier’ should I use for ‘Option’? ‘Alt’ ?
(sorry, but lazy to start new topic)
lacks some standard keyboard MacOS shortcuts) and crashes occasionally. The top menu UI needs some work too, but that could be a MojoX problem
Can you explain these shortcut and menu problem in ted2go topic or on github by issues?
Are these shortcuts pretty cool – https://developer.android.com/studio/intro/keyboard-shortcuts.html ?
I like this idea. Will try.
Also I want to add Tips dialog at startup, and irc chat as a tip.
I think will be better to show “welcome to chat” dialog, with description and where users can enter nickname and set checkbox “connect automatically”.
Thanks for explanation, and for ‘global’ inside of method body.
Here is splitted-by-classes version:
Monkey1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980Class RightDock Extends ScrollViewExtPrivateMethod FirstGrabSizes( newSize:Vec2i,prevSize:Vec2i )Print "sizes: "+newSize+", "+prevSize'Scroll = newSize * 0.5Scroll = AvailableScroll * 0.5SizeChanged-=FirstGrabSizes ' unsubscribesEndPublicMethod New()Layout="fill"ScrollBarsVisible = TrueLocal newStyle := Style.Copy()newStyle.BackgroundColor = Color.GreynewStyle.BorderColor = Color.BlacknewStyle.Font = TestGui.smallFontStyle = newStyleLocal graph:=New GraphViewContentView = graph' subscribes to changesSizeChanged+=FirstGrabSizesEndMethod OnRender( canvas:Canvas ) OverrideSuper.OnRender( canvas )canvas.Color = Color.Aluminumcanvas.DrawText( "size:" + Frame + " ,scroll:" + Scroll , 5, 5 )EndEndClass ScrollViewExt Extends ScrollViewPrivateField _prevSize:Vec2iField _panSpeed := 5.0' missed this method in mojoxProperty AvailableScroll:Vec2i()' also need to calc paddings, etcLocal xx:=Max( 0,MeasuredSize.x-VisibleRect.Width )Local yy:=Max( 0,MeasuredSize.y-VisibleRect.Height )Return New Vec2i( xx,yy )EndPublicField SizeChanged:Void( newSize:Vec2i,prevSize:Vec2i )ProtectedMethod OnMouseEvent( event:MouseEvent ) OverrideSelect event.TypeCase EventType.MouseWheelScroll = New Vec2i( Scroll.X+(event.Wheel.X*_panSpeed), Scroll.Y-(event.Wheel.Y*_panSpeed) )App.RequestRender()EndEnd' store prev sizeMethod OnMeasure:Vec2i() Override_prevSize=MeasuredSizeReturn Super.OnMeasure()End' check new size and fire SizeChanged event if necessaryMethod OnLayout() OverrideSuper.OnLayout()Local cur:=MeasuredSizeIf cur<>_prevSize Then SizeChanged( cur,_prevSize )EndEndThere is my ‘improved’ version
Monkey1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071Class RightDock Extends ScrollViewPrivateField _panSpeed := 5.0Field _prevSize:Vec2iMethod FirstGrabSizes( newSize:Vec2i,prevSize:Vec2i )Print "sizes: "+newSize+", "+prevSize'Scroll = newSize * 0.5Scroll = AvailableScroll * 0.5SizeChanged-=FirstGrabSizes ' unsubscribesEnd' missed this method in mojoxProperty AvailableScroll:Vec2i()' also need to calc paddings, etcLocal xx:=Max( 0,MeasuredSize.x-VisibleRect.Width )Local yy:=Max( 0,MeasuredSize.y-VisibleRect.Height )Return New Vec2i( xx,yy )EndPublicField SizeChanged:Void( newSize:Vec2i,prevSize:Vec2i )Method New()Layout="fill"ScrollBarsVisible = TrueLocal newStyle := Style.Copy()newStyle.BackgroundColor = Color.GreynewStyle.BorderColor = Color.BlacknewStyle.Font = TestGui.smallFontStyle = newStyleLocal graph:=New GraphViewContentView = graph' subscribes to changesSizeChanged+=FirstGrabSizesEndMethod OnRender( canvas:Canvas ) OverrideSuper.OnRender( canvas )canvas.Color = Color.Aluminumcanvas.DrawText( "size:" + Frame + " ,scroll:" + Scroll , 5, 5 )EndProtectedMethod OnMouseEvent( event:MouseEvent ) OverrideSelect event.TypeCase EventType.MouseWheelScroll = New Vec2i( Scroll.X+(event.Wheel.X*_panSpeed), Scroll.Y-(event.Wheel.Y*_panSpeed) )App.RequestRender()EndEnd' store prev sizeMethod OnMeasure:Vec2i() Override_prevSize=MeasuredSizeReturn Super.OnMeasure()End' check new size and fire SizeChanged event if necessaryMethod OnLayout() OverrideSuper.OnLayout()Local cur:=MeasuredSizeIf cur<>_prevSize Then SizeChanged( cur,_prevSize )EndEndAs for me, SizeChanged event should be a mojox core part.
Also I missed AvailableScroll:Vec2i property in ScrollView – to let us know is there scroll available and how much.
Above is a way how my BlaBlaViewExt were borned in ted2go.
To be precise, there is <> operator equivalent for ‘continue’ above
Monkey123If map <> -1)' DrawEndI use ‘continue’ to reduce nested IFs.
Keyword ‘Continue’ inside for loop is equivalent of Next, i.e. immediately go to the next loop frame. And here – skip all with index -1.
Look that topic: http://monkeycoder.co.nz/forums/topic/diddy2/
Heu! Really.
How do you get this event ?
My first commit date is 29 aug 2016.
- Resizable doesn’t work with persentage widths. There is pixel-sized _browsersTabView in ted2go
- To make scrolling :
- set button size more than view to enable scrolling: button.MinSize=New Vec2i( 0,1000 )
- change scroll like this: Scroll = Scroll + New Vec2i( event.Wheel.X * panSpeed, -event.Wheel.Y * panSpeed )
- assigning a value to Scroll.X is a mistake, because when you get access to Scroll variable you get copy of vec2 – say “hello” to struct type!
- in my case you assign whole vec2 and get right result.
- You can extends GraphView with DockingView. Or use internal docking view ‘wrapped’ with scrollview to manage views and have scrolling stuf.
- I am thinking about writing own gui system – I like the QT widgets layout, maybe I can implement some similar stuff.
What I like in QT and missed in monkey – SizePolicy basis, so you can just set sizePolicy=SizePolicy.Expanding and view will expand to all empty space, etc.
But it requires to write more complex and difficult layout system.
Also I tried to use operator += to add views, looks good.
Monkey12345678910111213141516171819Class VerticalLayout Extends DockingViewMethod New( topToBottom:Bool=True )_topToBottom=topToBottomLayout="fill-y"EndOperator += :Void( view:View )Self.AddView( view,_topToBottom ? "top" Else "bottom" )EndPrivateField _topToBottom:BoolEndand usage is
Monkey1234Local lay:=New VerticalLayoutlay += New Label( "Line 1" )lay += New Label( "Line 2" )lay += New Label( "Line 3" )Yes, it have intellisense, except of local variables.
September 1, 2017 at 7:29 am in reply to: Fu***ng message " *** Forbidden. Message seems to be spam. *** " #10186Did you totally disable anti-spam?
There are many anti-spam plugins for wordpress. Maybe you get luck with another one.
-
AuthorPosts