Programming Resources

Mark K. Jowett, Ph.D.

A collection of links and resources that you may find helpful!
(Note: This page is currently under development--with subject areas and links forthcoming.)



Programming/Coding



Programming Concepts

Java:
            Package (e.g., folder in file directory): used to group related classes and interfaces, and avoid name conflicts.
            Library: collection of packages, and package is collection of classes and interfaces.
					
Token: single "element" (i.e., smallest element recognized by compiler)
Token types: Examples: reserved words "new" and "void" are recognized as tokens in various languages.
Likewise, mathematical operators are recognized as tokens in most programming languages: +, -, *, /, as well as other tokens.
Note: White space separate tokens, and comments are not considered tokens.



Types of Errors

  1. Syntax/Compilation "grammar errors," misspelling, missing punctuation (e.g., comma, semi-colon)
  2. Run Time Errors - division by zero, open a file that doesn't exist
  3. Logic - design flaw (hardest to find and fix)
    Examples: Multiplying when you should be dividing. Displaying the wrong message.
Error-checking:
  1. Use "print" statements in code.
  2. Comment out code, rather than deleting.
Types of Errors



HTML

Doctypes, Validators, Testing:
W3C Web Accessibility Initiative (WAI): Selecting Colors:
*Note*: Understanding WCAG 2.0 level AA requires a contrast ratio of at least 4.5:1 for normal text.

Specification: Understanding Contrast
AA vs AAA:
"The contrast ratio of 4.5:1 was chosen for level AA because it compensated for the loss in contrast sensitivity usually experienced by users with vision loss equivalent to approximately 20/40 vision. (20/40 calculates to approximately 4.5:1.) 20/40 is commonly reported as typical visual acuity of elders at roughly age 80.

The contrast ratio of 7:1 was chosen for level AAA because it compensated for the loss in contrast sensitivity usually experienced by users with vision loss equivalent to approximately 20/80 vision. People with more than this degree of vision loss usually use assistive technologies to access their content (and the assistive technologies usually have contrast enhancing, as well as magnification capability built into them). The 7:1 level therefore generally provides compensation for the loss in contrast sensitivity experienced by users with low vision who do not use assistive technology and provides contrast enhancement for color deficiency as well."



.NET/C#/VB

.NET training videos:



Python



Android Studio

  1. Color Names Supported by All Browsers (140 color names ): colors.xml
  2. Android App ImageView Borders (removing space between border and image)
  3. 1. Rt-click the drawable folder and choose New > File
    2. Name it: image_border.xml
    3. Paste the following code into the file, and modify the width and color to your liking:
                  
                    <?xml version="1.0" encoding="utf-8"?>
                    <shape xmlns:android="http://schemas.android.com/apk/res/android">
    	              <stroke
    		            android:width="3dp"
    		            android:color="#ccccff" />
                    </shape>
                  
    4. In activity_main.xml (or, other activity where image is located), add the following code to the ImageView widget:
                  
                    android:padding="3dp"
                    android:background="@drawable/image_border"
                    android:adjustViewBounds="true"
                  
                  Note: Set adjustViewBounds to true to adjust ImageView bounds to preserve its aspect ratio.
    					  


***** STOP! **********************

Lesson x - Misc