diff --git a/stepmania/Utils/Theme/Analyzer.exe b/stepmania/Utils/Theme/Analyzer.exe new file mode 100755 index 0000000000..f0d55a4ba1 Binary files /dev/null and b/stepmania/Utils/Theme/Analyzer.exe differ diff --git a/stepmania/Utils/Theme/Analyzer.frm b/stepmania/Utils/Theme/Analyzer.frm new file mode 100644 index 0000000000..a36113a38a --- /dev/null +++ b/stepmania/Utils/Theme/Analyzer.frm @@ -0,0 +1,227 @@ +VERSION 5.00 +Begin VB.Form frmMain + BorderStyle = 1 'Fixed Single + Caption = "Dirty theme metrics analyzer" + ClientHeight = 5895 + ClientLeft = 45 + ClientTop = 330 + ClientWidth = 8190 + LinkTopic = "Form1" + MaxButton = 0 'False + MinButton = 0 'False + ScaleHeight = 5895 + ScaleWidth = 8190 + StartUpPosition = 3 'Windows Default + Begin VB.CommandButton cmdRemoveCommonMetrics + Caption = "Remove common metrics && reprint screens (must find common metrics first)" + Height = 495 + Left = 4920 + TabIndex = 9 + Top = 2040 + Width = 3135 + End + Begin VB.TextBox txtOutput + Height = 3375 + Left = 2400 + MultiLine = -1 'True + ScrollBars = 3 'Both + TabIndex = 8 + Top = 2520 + Width = 5775 + End + Begin VB.CommandButton Command1 + Caption = " "" Then + txtOutput = txtOutput + CommonLines(i) + vbCrLf + End If + + Next i +End Sub + +Private Sub cmdRemoveCommonMetrics_Click() + txtOutput = "" + For i = 1 To lstToDoScreens.ListCount + For j = 0 To NUMCOMMONS + foundmetric = False + For k = 0 To NumMetrics(Val(lstToDoScreens.List(i - 1)) - 1) + MetricX$ = Screens(Val(lstToDoScreens.List(i - 1)) - 1, k) + If CommonLines(j) = MetricX$ Then + foundmetric = True + Exit For + End If + Next k + If foundmetric = True Then + Screens(Val(lstToDoScreens.List(i - 1)) - 1, k) = "" + End If + Next j + Next i + + For i = 1 To lstToDoScreens.ListCount + For j = 0 To NumMetrics(Val(lstToDoScreens.List(i - 1)) - 1) + MetricX$ = Screens(Val(lstToDoScreens.List(i - 1)) - 1, j) + If MetricX$ <> "" Then + txtOutput = txtOutput + MetricX$ + vbCrLf + End If + Next j + Next i + +End Sub + +Private Sub Command1_Click() + If lstToDoScreens.ListIndex < 0 Then Exit Sub + lstToDoScreens.RemoveItem (lstToDoScreens.ListIndex) +End Sub + +Private Sub Dir_Change() + File = Dir +End Sub + +Private Sub Drive_Change() + Dir = Drive + File = Drive +End Sub + +Private Sub File_Click() + NumScreens = 0 + For i = 0 To 1000 + NumMetrics(i) = 0 + Next i + CurScreen$ = "" + lstScreens.Clear + + Open Dir + "\" + File For Binary As #1 + t = 1 + k$ = String$(2, " ") + xLine$ = "" + + While Not EOF(1) + Get #1, t, k$ + While k$ <> vbCr + vbLf And Not EOF(1) + t = t + 1 + xLine$ = xLine$ + Mid$(k$, 1, 1) + Get #1, t, k$ + Wend + t = t + 2 + If Mid(xLine$, 1, 1) = "[" Then + Screens(NumScreens, 0) = Str(NumScreens + 1) + ":" + xLine$ + NumMetrics(NumScreens) = 1 + NumScreens = NumScreens + 1 + lstScreens.AddItem (Str(NumScreens) + ":" + xLine$) + Else + Screens(NumScreens - 1, NumMetrics(NumScreens - 1)) = xLine$ + NumMetrics(NumScreens - 1) = NumMetrics(NumScreens - 1) + 1 + End If + xLine$ = "" + Wend + Close #1 +End Sub + diff --git a/stepmania/Utils/Theme/Analyzer.vbp b/stepmania/Utils/Theme/Analyzer.vbp new file mode 100644 index 0000000000..2410a12f2a --- /dev/null +++ b/stepmania/Utils/Theme/Analyzer.vbp @@ -0,0 +1,34 @@ +Type=Exe +Form=Analyzer.frm +Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#..\..\..\..\WINDOWS\System32\STDOLE2.TLB#OLE Automation +IconForm="frmMain" +Startup="frmMain" +ExeName32="Analyzer.exe" +Command32="" +Name="Project1" +HelpContextID="0" +CompatibleMode="0" +MajorVer=1 +MinorVer=0 +RevisionVer=0 +AutoIncrementVer=0 +ServerSupportFiles=0 +VersionCompanyName="Home" +CompilationType=0 +OptimizationType=0 +FavorPentiumPro(tm)=0 +CodeViewDebugInfo=0 +NoAliasing=0 +BoundsCheck=0 +OverflowCheck=0 +FlPointCheck=0 +FDIVCheck=0 +UnroundedFP=0 +StartMode=0 +Unattended=0 +Retained=0 +ThreadPerObject=0 +MaxNumberOfThreads=1 + +[MS Transaction Server] +AutoRefresh=1 diff --git a/stepmania/Utils/Theme/Analyzer.vbw b/stepmania/Utils/Theme/Analyzer.vbw new file mode 100644 index 0000000000..75abb676bb --- /dev/null +++ b/stepmania/Utils/Theme/Analyzer.vbw @@ -0,0 +1 @@ +frmMain = 44, 44, 655, 542, , 22, 22, 622, 449, C