Creating a chatbot 2

Post date: Oct 22, 2014 1:51:24 PM

Creating a GUI for the artificial intelligence is an important part of the design process. the look and feel of the app can also give you the feeling and look of a professional application.

Apples IOS UI Ideals

    • Deference. The UI helps people understand and interact with the content, but never competes with it.

    • Clarity. Text is legible at every size, icons are precise and lucid, adornments are subtle and appropriate, and a sharpened focus on functionality motivates the design.

    • Depth. Visual layers and realistic motion impart vitality and heighten people’s delight and understanding.

Creating the GUI

When creating the gui i have used a transparent gif file for my skin file.

the transparent for is achieved by new features in the form property s, although this can also leave problems with form movement also.

Additional code has been added to allow for mouse movement of the form.

'form positioning

'-----------------------------------------------------------------------------------------

Private x, y As Integer

Private newpoint As New Point

'Form Movement

''' <summary>

''' This samples solves the problem for the form not being moveable.

''' </summary>

''' <param name="sender"></param>

''' <param name="e"></param>

''' <remarks></remarks>

Private Sub Frm_AI_MouseDown(sender As Object, e As MouseEventArgs) Handles Me.MouseDown

Try

' Form movement set integers

x = Control.MousePosition.X - Me.Location.X

y = Control.MousePosition.Y - Me.Location.Y

Catch ex As Exception

End Try

End Sub

''' <summary>

''' This samples solves the problem for the borderless form not being moveable.

''' </summary>

''' <param name="sender"></param>

''' <param name="e"></param>

''' <remarks></remarks>

Private Sub Frm_AI_MouseMove(sender As Object, e As MouseEventArgs) Handles Me.MouseMove

Try

' Form movement movement

If e.Button = Windows.Forms.MouseButtons.Left Then

newpoint = Control.MousePosition

newpoint.X -= (x)

newpoint.Y -= (y)

Me.Location = newpoint

End If

Catch ex As Exception

End Try

End Sub

'-----------------------------------------------------------------------------------------

the source code for this step is available to download at the bottom of the page.