Skip to content

Instantly share code, notes, and snippets.

Stephen Quan stephenquan

Block or report user

Report or block stephenquan

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@stephenquan
stephenquan / MapIdentify.apa
Last active Sep 6, 2019
MapIdentify Applet for ArcPad
View MapIdentify.apa
<?xml version="1.0" encoding="UTF-8"?>
<ArcPad>
<APPLET>
<SYSTEMOBJECTS>
<MAP onidentify="OnIdentify"/>
</SYSTEMOBJECTS>
</APPLET>
<SCRIPT src="MapIdentify.vbs" language="vbscript"/>
</ArcPad>
@stephenquan
stephenquan / AppStudio_Maze_Solver.qml
Last active Jul 30, 2019
AppStudio_Maze_Solver.qml
View AppStudio_Maze_Solver.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
import QtQuick.Layouts 1.12
import ArcGIS.AppFramework 1.0
Item {
ColumnLayout {
anchors.fill: parent
anchors.margins: 10
@stephenquan
stephenquan / AppStudio_20190717_ForOfDest.qml
Created Jul 17, 2019
AppStudio_20190717_ForOfDest.qml
View AppStudio_20190717_ForOfDest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
Item {
Button {
text: qsTr("Run For Of With Destructuring Sample")
onClicked: {
let census = [
{ country: "France", population: 66.99 },
{ country: "Australia", population: 24.6 },
View AppStudio_20190717_ForOf.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
Item {
Button {
text: qsTr("Run For Of Sample")
onClicked: {
let census = [
{ country: "France", population: 66.99 },
{ country: "Australia", population: 24.6 },
@stephenquan
stephenquan / AppStudio_20190717_ForWithIndex.qml
Created Jul 17, 2019
AppStudio_20190717_ForWithIndex.qml
View AppStudio_20190717_ForWithIndex.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
Item {
Button {
text: qsTr("Run For Sample")
onClicked: {
var census = [
{ country: "France", population: 66.99 },
{ country: "Australia", population: 24.6 },
@stephenquan
stephenquan / AppStudio_20190703_RegExpValidatorTest.qml
Created Jul 1, 2019
AppStudio_20190703_RegExpValidatorTest.qml
View AppStudio_20190703_RegExpValidatorTest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
TextField {
validator: RegExpValidator {
regExp: /[0-9]{3}-[A-Za-z]{3}/
}
placeholderText: qsTr("Type in a license plate of the pattern 999-AAA")
text: "123-XYZ"
color: acceptableInput ? "green" : "red"
@stephenquan
stephenquan / AppStudio_20190703_DoubleValidatorTest.qml
Created Jul 1, 2019
AppStudio_20190703_DoubleValidatorTest.qml
View AppStudio_20190703_DoubleValidatorTest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
TextField {
validator: DoubleValidator {
bottom: 25.0
top: 75.0
}
placeholderText: qsTr("Type in a number between 25.0 and 75.0")
text: "34.5"
@stephenquan
stephenquan / AppStudio_20190703_IntValidatorTest.qml
Created Jul 1, 2019
AppStudio_20190703_IntValidatorTest.qml
View AppStudio_20190703_IntValidatorTest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
TextField {
validator: IntValidator {
bottom: 25
top: 75
}
placeholderText: qsTr("Type in an integer between 25 and 75")
text: "34"
@stephenquan
stephenquan / AppStudio_20190703_InputMaskTest.qml
Last active Jul 1, 2019
AppStudio_20190703_InputMaskTest.qml
View AppStudio_20190703_InputMaskTest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
TextField {
inputMask: "999-AAA"
placeholderText: qsTr("Type in a license plate of the pattern 999-AAA")
text: "123-XYZ"
color: acceptableInput ? "green" : "red"
selectByMouse: true
}
@stephenquan
stephenquan / AppStudio_20190703_InputValidatorTest.qml
Last active Jul 1, 2019
AppStudio_20190703_InputValidatorTest.qml
View AppStudio_20190703_InputValidatorTest.qml
import QtQuick 2.12
import QtQuick.Controls 2.5
import ArcGIS.AppFramework 1.0
Item {
TextField {
width: parent.width
validator: InputValidator {
validate: function (input, position) {
if (input.match(/unicorn/)) {
You can’t perform that action at this time.