Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/05/2022 in all areas

  1. jchd

    E's not E

    There are countless examples of such "visual collisions", depending of the font used for display. I especially like the : vs. ꞉ which makes "Z꞉abc.xyz" a valid filename in the current directory. For instance: Local $aDiff = [ _ "EЕ", _ ":꞉", _ "ÐĐƉ", _ "êȇ", _ "eе", _ "ΩΩ", _ "OΟ" _ ] Local $c, $t For $s In $aDiff $t = "" For $i = 1 To StringLen($s) $c = StringMid($s, $i, 1) $t &= $c & @TAB & AscW($c) & @LF Next MsgBox(0, "", $t) Next This will expand as new scripts (written languages) are constantly added to the Unicode set. There are special measures taken for the URLs if/when Unicode is allowed there to avoid such pitfalls.
    2 points
  2. KaFu

    E's not E

    The wonder of Unicode 🙄, this one took me a little while. Fyi, if this ever bugs someone else. MsgBox(0, "", AscW("Е")) MsgBox(0, "", AscW("E"))
    1 point
  3. An example : #include <WindowsConstants.au3> Global $SS_CENTER, $_CompteArebour = 60000, $_Minutes, $_Seconds $_GuiCountDown = GUICreate ( "CountDown...", 500, 200, @DesktopWidth/2 -250, @DesktopHeight/2 -100, $WS_EX_TOPMOST ) GUISetBkColor ( 0xFFFF00 ) $TimeLabel = GUICtrlCreateLabel ( "", 35, -10, 480, 180, $SS_CENTER ) GUICtrlSetFont ( -1, 125, 800 ) GUISetState ( ) WinSetOnTop ( $_GuiCountDown, "", 1 ) $TimeTicks = TimerInit ( ) While 1 _Check ( ) Sleep ( 200 ) WEnd Func _Check ( ) $_CompteArebour -= TimerDiff ( $TimeTicks ) $TimeTicks = TimerInit ( ) Local $_MinCalc = Int ( $_CompteArebour / ( 60 * 1000 ) ), $_SecCalc = $_CompteArebour - ( $_MinCalc * 60 * 1000 ) $_SecCalc = Int ( $_SecCalc / 1000 ) If $_MinCalc <= 0 And $_SecCalc <= 0 Then GUISetBkColor ( 0xFF0000, $_GuiCountDown ) GUICtrlSetData ( $TimeLabel, "Bye !" ) Sleep ( 1000 ) ; If @Compiled Then Shutdown ( 13 ) Exit Else If $_MinCalc <> $_Minutes Or $_SecCalc <> $_Seconds Then $_Minutes = $_MinCalc $_Seconds = $_SecCalc GUICtrlSetData ( $TimeLabel, StringFormat ( "%02u" & ":" & "%02u", $_Minutes, $_Seconds ) ) If $_Minutes = 0 And $_Seconds <= 10 Then Beep ( 1200, 100 ) GUISetBkColor ( 0xA093FF, $_GuiCountDown ) EndIf EndIf EndIf EndFunc ;==> _Check ( )
    1 point
×
×
  • Create New...