Page 1 of 1

LCARS Star Trek

Posted: 26 May 2022, 02:53
by jrachr
Good Day. Need some help as this is way beyond me. Does anyone out there know how to take this LCARS interface and Make it work with my existing GUI. I can add all my Websites. Just need to change my existing Gui to an LCARS gui if possible. Here is the Lcars website and my existing code. Tk's

https://sourceforge.net/projects/lcars-system-3/
https://www.deviantart.com/pashaak

Code: Select all

;-  Date-modified =20220204     Gui +Owner +lastfound -caption
;-- Date-modified =20220130     GUI background transparent user amateur+
;-- Date-modified =20220128     GUI transparency change with button alt+up/down
;-- Date-modified =20211107     not needed add # for title,Font/Color definitions are in column3 
;-- Date-modified =20211106     different fonts and size for buttons
;-- Date-modified =20211104/3   different colors for BUTTONS after TITLE or SPACE 
;-- Date-modified =20210917/3   csv Halifax / TITLE-button has another color / +Resize 
;-- Date-modified =20210917/2   add TITLE or SPACE between buttons
;-- Date-modified =20210915     color buttons
;-- Date-modified =20210914     one button starts 3 URL's or programs 
;--------------------------------------------------------------------------------
#NoTrayIcon
#Warn
#NoEnv
#Singleinstance Force
filename1:="Jr's Shortcut's"
setworkingdir,%a_scriptdir%
Settitlematchmode,2
Gui,2:default
transform,s,chr,127    ;- delimiter for stringsplit
WA:=A_screenwidth,HA:=A_screenheight,xx:=100
Gui,2: -dpiscale  +Owner +LastFound -caption
WinSet, TransColor, EEAA99                                   ;- hide  background
Gui,2: Color, EEAA99                                         ;- color background
;--------------------
col1:="",col2:="",col3:="",col4:=""
vert:=25                    ;-- change here how many vertikal buttons want have ( inclusive EMPTY-LINE and TITLE )
;                           but then also change GuiSize ( Width and Height )
;                           add a separator line for better view after defined variable 'vert' ) here after line 18 > ==============                         
;--------------------
;-
;- I don't know which is the best font-size depending screen-size or scaling 
;------ BUTTON-TITLE ---------------
FontTitle:="Trebuchet MS" ,SizeTitle:="16 norm bold",colbgr:="388E8E",coltxt:="Yellow"
;----------------------------------
;---------------------  Button-NAME - URL1 - URL2 - URL3 ----------------------------------------------------
;- if Column-2 is empty :
;- all definitions are in Column-3  : FontSize|FONT|BackGroundColor|TextColor
;-
;- Define the next rows :
;- _S;;15 Bold|Verdana|Green|Black;                      ;--  _S only space
;-    OR
;- TOOLS;;11 norm|Verdana|D5D1C9|black;                  ;--  TITLE 
;-
;- CHARMAP_CALC_NOTEPAD;charmap;calc;notepad             ;--  run URL or program (1-3)
;------------------------------------------------------------------------------------------------------------
;-
sectx=   
(Ltrim comments Join`r`n % 
==================================================
Halifax_Retales;;13 Bold|Verdana|4DA6FF|Black;
Halifax_Retales_Chat;https://www.facebook.com/groups/HalifaxReTalesChat/?fref=mentions;;
Halifax_Retales_Facebook;https://www.facebook.com/HalifaxReTales;;
Halifax_Retales_Faves;https://faves.retales.ca/;;
Halifax_Retales_Twitter;https://twitter.com/HalifaxReTales;;
_S;;;
_S;;;
Stanfield_Airport;;13 Bold|Verdana|B284BE|Black;
Halifax_Airport;https://halifaxstanfield.ca/flight-information/departures/;;
Halifax_Airport_Twitter;https://twitter.com/HfxStanfield;;
Highway_Conditions;https://511.novascotia.ca/en/map.html#l=48&x=-7053745&y=5628400&z=3&lb=1&rb=1;;
Google_Maps;https://www.google.com/maps/@44.9471296,-63.3762733,11.25z
_S;;;
Tools;;13 Bold|Verdana|cc4499|Black;
App_Folder;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Appilcation Folder.ahk;;
Ostomy_Supplies;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Ostomy Supplies.ahk;;
Programs;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Program's.ahk;;
Windows_11_Tools;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Window's 11 Tool's.ahk;;
_S;;;
Utilities;;13 Bold|Verdana|4DA6FF|Black;
Eastlink;https://my.eastlink.ca/myaccount;;
Global_Benifits;https://www.globalben.com/Account/Login?logout=True;;
NS_Power_Outage_Map;http://outagemap.nspower.ca/external/default.html
NS_Pharmacare;https://ns.211.ca/services/medavie-blue-cross/pharmacare-boarding-transportation-and-ostomy-program/
Virgin_Plus;https://www.virginplus.ca/en/login/index.html;;
==================================================
Weather;;12 Bold|Verdana|DD4444|Black;
Canada_Hurricane_Center;https://weather.gc.ca/hurricane/track_e.html;;
Environment_Canada;https://weather.gc.ca/city/pages/ns-40_metric_e.html;;
National_Hurricane_Center;https://www.nhc.noaa.gov/?atl;;
The_Weather_Network;https://www.theweathernetwork.com/ca/weather/nova-scotia/halifax-stanfield-intl-airport;;
_S;;;
_S;;;
Shopping;;13 Italic|Verdana|ff7700|Black;
Amazon_Canada;https://www.amazon.ca/;;
Amazon_Canada_Phone;https://gethuman.com/phone-number/Amazon-Canada;;
_S;;;
_S;;;
Costco_Canada;https://www.costco.ca/?langId=-24;
Ikea_Canada;https://www.ikea.com/ca/en/;
Walmart_Canada;https://www.walmart.ca/en;
_S;;;
_S;;;
_S;;;
_S;;;
Bank;;13 Bold|Verdana|33FF33|Black;
TD_Bank;https://authentication.td.com/uap-ui/index.html?consumer=easyweb&locale=en_CA#/login/easyweb-getting-started;;
_S;;;
_S;;;
Tims_Card;;13 Bold|Verdana|DD4444|Black;
Tim_Hortons;https://www.timhortons.ca/;;
==================================================
Sports;;13 Bold|Verdana|DD4444|Black;
ESPN;https://www.espn.com/;;
Sportsnet;https://www.sportsnet.ca/;;
TSN_TV_Schedule;https://www.tsn.ca/live/schedule;;
TSN_Sports_News;https://www.tsn.ca/;;
_S;;;
_S;;;
News;;13 Bold|Verdana|ff7700|Black;
Chronicle_Herald;https://www.thechronicleherald.ca/;;
Global_News;https://globalnews.ca/halifax/;;
CityNews_Everywhere;https://www.halifaxtoday.ca/;;
_S;;;
NY_Post;https://nypost.com/;;
Las_Vegas_Sun;https://lasvegassun.com/;;
CNN_News;https://www.cnn.com/;;
_S;;;
_S;;;
_S;;;
_S;;;
EMail;;13 Bold|Verdana|FF8866|Black;
Thunderbird;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Firefox\Thunderbird.ahk;;
_S;;;
_S;;;
Schedule;;13 Bold|Verdana|DD4444|Black;
Calendar;C:\Users\Jr\AppData\Roaming\Microsoft\Windows\Network Shortcuts\Shortcuts\Calendar - Shortcut.lnk;;
==================================================
AutoHotkey_Shortcuts;;12 Bold|Verdana|4DA6FF|Black;
AHK_Scripts;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts;;
AHK_Running_Scripts;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\AHK Tool's\Ahk Task Manager.ahk;;
Forums;https://www.autohotkey.com/boards/viewforum.php?f=76;;
Master_Script_Reboot;E:\PortableApps\PortableApps\AutoHotkeyPortable\Data\Jr's Script.ahk;;
Window_Spy;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\AHK Tool's\WindowSpy.ahk;;
_S;;;
TV;;13 Bold|Verdana|B284BE|Black;
TV_Guide;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\TV Guide.ahk;;
TV_Guide_Sports;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\TV Guide Sports.ahk;;
_S;;;
_S;;;
Halifax_Development;;11 Bold|Verdana|33CC99|Black;
Halifax_Peninsula;https://skyscraperpage.com/forum/forumdisplay.php?f=223;;
_S;;;
Brave_Tools;;11 Bold|Verdana
Brave_Portable_Cache_Clear;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Brave Portable Cache Clear.ahk;;
Brave_Fullscreen;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Fullscreen.ahk;;
_S;;;
Favorites;;13 Bold|Verdana|4DA6FF|Black;
Firefox_Portable;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Firefox Portable.ahk;;
Brave_Portable;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Brave Portable.ahk;;
Portable_Apps;E:\PortableApps\Start.exe - Shortcut.lnk;;
TV_Show_Tracker;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\My TV Show Tracker.ahk;;
Your_Phone;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Your Phone.ahk;;
)
;---------------------
loop,parse,sectx,`n,`r
  {
  x:=a_loopfield
  if x contains =====
     continue
  stringsplit,k,x,`;
  col1 .= k1 . s ,  col2 .= k2 . s ,  col3 .= k3 . s ,  col4 .= k4 . s
  }
stringsplit,q,col1,%s%
stringsplit,m,col2,%s%
stringsplit,n,col3,%s%
stringsplit,o,col4,%s%
;-----------------------
i:=0,totx:=(q0-1),x:= (wa*1)/xx ,y:= (ha*1)/xx,  w:= (wa*14 )/xx,h:= (ha*2.5)/xx,v:=(ha*3)/xx        ;- button x y w h v=distance vertical
;------------------------------
Loop,%totx%
  {
  i++
  btname:="" , column2:="" , column3:="" , column4:=""
  BTName := q%i% ,  column2:= m%i% , column3:= n%i%, column4:= o%i%
  if (btname="_S")
    {
    Gui,2:Add,Text,            x%x%   y%y% w%w%  h%h% center,                               ;- if space added
    stringsplit,z,column3,`|
    }
  ;-----------------
  else if (column2="" and btname !="_S")    ;- add title and background
    {
      Gui,2:font,s%SizeTitle% ,%FontTitle%
      Gui,2:Add,Progress,        x%x%   y%y% w%w%  h%h%  Disabled Background%colbgr%       ;- TITLE Button-backgroundcolor
      Gui,2:Add,Text,            xp    yp     wp    hp   c%coltxt%  BackgroundTrans Center 0x200  v%btname%_%i% ,%btname%
      stringsplit,z,column3,`|
    }
  else if (BTName !="" and column2 !="") 
    {
    ;---------------------------
    ;- after TITLE or SPACE > other buttons color background and text
    ;---
    Gui,2:font,s%z1%,%z2%
    Gui,2:Add,Progress,            x%x%   y%y% w%w%  h%h%  Disabled Background%Z3%
    Gui,2:Add,Text,                xp    yp     wp    hp   c%Z4%  BackgroundTrans Center 0x200 gStart1 v%btname%_%i% ,%btname%
    }
  y+=%v%
  Md:=mod(i,vert)
  if md=0
     x+=(wa*15)/xx,y:=(ha*1)/xx   ;- if modulo = 0 them move to new x (right)  y (top)
  }

;--- 2 Buttons if needed instead of ESC  or alt+ESC -------------------
/*  
x:=(wa*51)/xx,y:=(ha*57)/xx,w:=(wa*8)/xx,h:=(ha*2.4)/xx 
Gui,2:add,button,x%x% y%y% h%h% w%w% gMinimize,MINIMIZE
;-
x:=(wa*62)/xx,y:=(ha*57)/xx,w:=(wa*8)/xx,h:=(ha*2.4)/xx 
Gui,2:add,button,x%x% y%y% h%h% w%w% gClose,CLOSE
*/  
;--------- GUISIZE -------------------------------------------------------
x:=(wa*20)/xx,y:=(ha*15)/xx,w:=(wa*67)/xx,h:=(ha*85)/xx   ;- GUI x y w h
;x:=(wa*.1)/xx,y:=(ha*.1)/xx,w:=(wa*71)/xx,h:=(ha*60)/xx   ;- GUI x y w h
Gui,2:Show, x%x% y%y% h%h% w%w%,%filename1%
Return
;-------------------------------------------------------------------------
/*
CLOSE:
2Guiclose:
exitapp
;--------------
Minimize:
Gui,2:minimize
return
*/

;-------------------------------------------------------------------------
esc::exitapp                                                                         ;- quit this script with ESC
!esc::Gui,2:minimize                                                                 ;- minimize this script with alt+ESC
;--------------- start --------------------------
start1:
gui,2:submit,nohide
Mousegetpos,,,,Ctrl       ;- Button1
r:= a_guicontrol          ;- vVar ( Buttonname )
stringtrimleft,ct,ctrl,6  ;- Button-(1)
clm2:= m%ct%,clm3:= n%ct%,clm4:= o%ct%
;msgbox, 262208, ,R=%r%`nCT=%ct%`nCTRL=%ctrl%`nURL1=%clm2%`nURL2=%clm3%`nURL3=%clm4%
try
 run,%clm2%
catch,err 
  { 
  gosub,checkerror
  return
  }
try
 run,%clm3%
catch,err
  { 
  gosub,checkerror
  return
  }
try
 run,%clm4%
catch,err 
  { 
  gosub,checkerror
  return
  }
Gui,2:minimize
return
;-----------------
Checkerror:
    x1:="Message=" . err.Message
    x2:="Extra  =" . err.extra
    x3:="File   =" . err.file
    x4:="Line   =" . err.line
    x5:="What   =" . err.what
    msgbox, 262208,ERROR,Error=`n%x1%`n----------------------`n%x2%`n%x3%`n%x4%`n%x5%`n--------------------`n
return
;================================ END SCRIPT ================================


Re: LCARS Star Trek

Posted: 12 Nov 2022, 12:17
by jrachr
Hi all.Been a while so I thought I would ask again if anyone out there could help me out. Tk's

Re: LCARS Star Trek

Posted: 12 Nov 2022, 15:25
by garry
hello @jrachr
I had this , a picture in background and color buttons
EDIT : modified to move gui

Code: Select all

;-------- saved at 2022-11-12 --------------
;- LCARS Star Trek / add a picture in background 
;- https://www.autohotkey.com/boards/viewtopic.php?f=76&t=104535

;-  Date-modified =20221112     Move Gui if click on background-picture
;-  Date-modified =20220603     Add picture behind text > Button-rounded-corner / can add a x background picture to GUI , color doesn't matter
;-  Date-modified =20220601     Add background picture / textcolor defined as example yellow if picture has black background 
;-  Date-modified =20220204     Gui +Owner +lastfound -caption
;-- Date-modified =20220130     GUI background transparent user amateur+
;-- Date-modified =20220128     GUI transparency change with button alt+up/down
;-- Date-modified =20211107     not needed add # for title,Font/Color definitions are in column3 
;-- Date-modified =20211106     different fonts and size for buttons
;-- Date-modified =20211104/3   different colors for BUTTONS after TITLE or SPACE 
;-- Date-modified =20210917/3   csv Halifax / TITLE-button has another color / +Resize 
;-- Date-modified =20210917/2   add TITLE or SPACE between buttons
;-- Date-modified =20210915     color buttons
;-- Date-modified =20210914     one button starts 3 URL's or programs 
;--------------------------------------------------------------------------------
#NoTrayIcon
;#Warn
#NoEnv
#Singleinstance Force
filename1:="Jr's Shortcut's"
setworkingdir,%a_scriptdir%
Settitlematchmode,2
Gui,2:default
transform,s,chr,127    ;- delimiter for stringsplit
WA:=A_screenwidth,HA:=A_screenheight,xx:=100
Gui,2: -dpiscale  +Owner +LastFound -caption
pict:="no"
;---------------------------------------------------------------------------
;---------- add background picture -----------------------------------------
url:="https://a.fsdn.com/con/app/proj/lcars-system-3/screenshots/PicFromNewImageGallery.png/max/max/1"
P1:=a_scriptdir . "\1.png"
ifnotexist,%p1%
  urldownloadtofile,%url%,%p1%
ifexist,%p1%  
 {  
 w:=(wa*67)/xx,h:=(ha*85)/xx   ;- GUI  w h
 Gui,2: Add, Picture, x0  y0  w%w% h%h%       , %P1%
 }
;---------------------------------------------------------------------------- 
;----------------- add background rounded button ---------------------------
url2:="https://www.seekpng.com/png/detail/92-926159_rounded-rectangle-button-png-botones-para-web-png.png"
P2:=a_scriptdir . "\blue.png"
ifnotexist,%p2%
  urldownloadtofile,%url2%,%p2%
ifexist,%p2%
 {
 ;pict:="yes"                                                ;- see blue buttons from P2 as background
 pict:="NO"                                                ;- see buttons with defined colors
 }
    
;--------------------------------------------------------------------------
WinSet, TransColor, EEAA99                                   ;- hide  background
Gui,2: Color, EEAA99                                         ;- color background
;--------------------
;--------------------
col1:="",col2:="",col3:="",col4:=""
vert:=25                    ;-- change here how many vertikal buttons want have ( inclusive EMPTY-LINE and TITLE )
;------ BUTTON-TITLE ---------------
FontTitle:="Trebuchet MS" ,SizeTitle:="16 norm bold",colbgr:="388E8E",coltxt:="Yellow"
;----------------------------------
;---------------------  Button-NAME - URL1 - URL2 - URL3 ----------------------------------------------------
;- if Column-2 is empty :
;- all definitions are in Column-3  : FontSize|FONT|BackGroundColor|TextColor
;-
;- Define the next rows :
;- _S;;15 Bold|Verdana|Green|Black;                      ;--  _S only space
;-    OR
;- TOOLS;;11 norm|Verdana|D5D1C9|black;                  ;--  TITLE 
;-
;- CHARMAP_CALC_NOTEPAD;charmap;calc;notepad             ;--  run URL or program (1-3)
;------------------------------------------------------------------------------------------------------------
;-
sectx=   
(Ltrim comments Join`r`n % 
==================================================
Halifax_Retales;;13 Bold|Verdana|4DA6FF|Black;
Halifax_Retales_Chat;https://www.facebook.com/groups/HalifaxReTalesChat/?fref=mentions;;
Halifax_Retales_Facebook;https://www.facebook.com/HalifaxReTales;;
Halifax_Retales_Faves;https://faves.retales.ca/;;
Halifax_Retales_Twitter;https://twitter.com/HalifaxReTales;;
_S;;;
_S;;;
Stanfield_Airport;;13 Bold|Verdana|B284BE|Black;
Halifax_Airport;https://halifaxstanfield.ca/flight-information/departures/;;
Halifax_Airport_Twitter;https://twitter.com/HfxStanfield;;
Highway_Conditions;https://511.novascotia.ca/en/map.html#l=48&x=-7053745&y=5628400&z=3&lb=1&rb=1;;
Google_Maps;https://www.google.com/maps/@44.9471296,-63.3762733,11.25z
_S;;;
Tools;;13 Bold|Verdana|cc4499|Black;
App_Folder;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Appilcation Folder.ahk;;
Ostomy_Supplies;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Ostomy Supplies.ahk;;
Programs;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Program's.ahk;;
Windows_11_Tools;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Jrs Shortcuts\Window's 11 Tool's.ahk;;
_S;;;
Utilities;;13 Bold|Verdana|4DA6FF|Black;
Eastlink;https://my.eastlink.ca/myaccount;;
Global_Benifits;https://www.globalben.com/Account/Login?logout=True;;
NS_Power_Outage_Map;http://outagemap.nspower.ca/external/default.html
NS_Pharmacare;https://ns.211.ca/services/medavie-blue-cross/pharmacare-boarding-transportation-and-ostomy-program/
Virgin_Plus;https://www.virginplus.ca/en/login/index.html;;
==================================================
Weather;;12 Bold|Verdana|DD4444|Black;
Canada_Hurricane_Center;https://weather.gc.ca/hurricane/track_e.html;;
Environment_Canada;https://weather.gc.ca/city/pages/ns-40_metric_e.html;;
National_Hurricane_Center;https://www.nhc.noaa.gov/?atl;;
The_Weather_Network;https://www.theweathernetwork.com/ca/weather/nova-scotia/halifax-stanfield-intl-airport;;
_S;;;
_S;;;
Shopping;;13 Italic|Verdana|ff7700|Black;
Amazon_Canada;https://www.amazon.ca/;;
Amazon_Canada_Phone;https://gethuman.com/phone-number/Amazon-Canada;;
_S;;;
_S;;;
Costco_Canada;https://www.costco.ca/?langId=-24;
Ikea_Canada;https://www.ikea.com/ca/en/;
Walmart_Canada;https://www.walmart.ca/en;
_S;;;
_S;;;
_S;;;
_S;;;
Bank;;13 Bold|Verdana|33FF33|Black;
TD_Bank;https://authentication.td.com/uap-ui/index.html?consumer=easyweb&locale=en_CA#/login/easyweb-getting-started;;
_S;;;
_S;;;
Tims_Card;;13 Bold|Verdana|DD4444|Black;
Tim_Hortons;https://www.timhortons.ca/;;
==================================================
Sports;;13 Bold|Verdana|DD4444|Black;
ESPN;https://www.espn.com/;;
Sportsnet;https://www.sportsnet.ca/;;
TSN_TV_Schedule;https://www.tsn.ca/live/schedule;;
TSN_Sports_News;https://www.tsn.ca/;;
_S;;;
_S;;;
News;;13 Bold|Verdana|ff7700|Black;
Chronicle_Herald;https://www.thechronicleherald.ca/;;
Global_News;https://globalnews.ca/halifax/;;
CityNews_Everywhere;https://www.halifaxtoday.ca/;;
_S;;;
NY_Post;https://nypost.com/;;
Las_Vegas_Sun;https://lasvegassun.com/;;
CNN_News;https://www.cnn.com/;;
_S;;;
_S;;;
_S;;;
_S;;;
EMail;;13 Bold|Verdana|FF8866|Black;
Thunderbird;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Firefox\Thunderbird.ahk;;
_S;;;
_S;;;
Schedule;;13 Bold|Verdana|DD4444|Black;
Calendar;C:\Users\Jr\AppData\Roaming\Microsoft\Windows\Network Shortcuts\Shortcuts\Calendar - Shortcut.lnk;;
==================================================
AutoHotkey_Shortcuts;;12 Bold|Verdana|4DA6FF|Black;
AHK_Scripts;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts;;
AHK_Running_Scripts;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\AHK Tool's\Ahk Task Manager.ahk;;
Forums;https://www.autohotkey.com/boards/viewforum.php?f=76;;
Master_Script_Reboot;E:\PortableApps\PortableApps\AutoHotkeyPortable\Data\Jr's Script.ahk;;
Window_Spy;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\AHK Tool's\WindowSpy.ahk;;
_S;;;
TV;;13 Bold|Verdana|B284BE|Black;
TV_Guide;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\TV Guide.ahk;;
TV_Guide_Sports;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\TV Guide Sports.ahk;;
_S;;;
_S;;;
Halifax_Development;;11 Bold|Verdana|33CC99|Black;
Halifax_Peninsula;https://skyscraperpage.com/forum/forumdisplay.php?f=223;;
_S;;;
Brave_Tools;;11 Bold|Verdana
Brave_Portable_Cache_Clear;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Brave Portable Cache Clear.ahk;;
Brave_Fullscreen;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Fullscreen.ahk;;
_S;;;
Favorites;;13 Bold|Verdana|4DA6FF|Black;
Firefox_Portable;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Firefox Portable.ahk;;
Brave_Portable;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Brave Portable.ahk;;
Portable_Apps;E:\PortableApps\Start.exe - Shortcut.lnk;;
TV_Show_Tracker;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\My TV Show Tracker.ahk;;
Your_Phone;E:\PortableApps\PortableApps\AutoHotkeyPortable\AHK Scripts\Your Phone.ahk;;
)
;---------------------
loop,parse,sectx,`n,`r
  {
  x:=a_loopfield
  if x contains =====
     continue
  stringsplit,k,x,`;
  col1 .= k1 . s ,  col2 .= k2 . s ,  col3 .= k3 . s ,  col4 .= k4 . s
  }
stringsplit,q,col1,%s%
stringsplit,m,col2,%s%
stringsplit,n,col3,%s%
stringsplit,o,col4,%s%
;-----------------------
i:=0,totx:=(q0-1),x:= (wa*1)/xx ,y:= (ha*1)/xx,  w:= (wa*14 )/xx,h:= (ha*2.5)/xx,v:=(ha*3)/xx        ;- button x y w h v=distance vertical
;------------------------------
Loop,%totx%
  {
  i++
  btname:="" , column2:="" , column3:="" , column4:=""
  BTName := q%i% ,  column2:= m%i% , column3:= n%i%, column4:= o%i%
  if (btname="_S")
    {
    if (pict="yes")
      Gui,2:Add,Text,                x%x%    y%y%     w%w%    h%h%   BackgroundTrans Center 0x200 
    else
      Gui,2:Add,Text,            x%x%   y%y% w%w%  h%h% center Backgroundtrans,                               ;- if space added
    stringsplit,z,column3,`|
    }
  ;-----------------
  else if (column2="" and btname !="_S")    ;- add title and background
    {
      Gui,2:font,s%SizeTitle% ,%FontTitle%
      if (pict="yes")
        Gui,2:Add,Text,            x%x%    y%y%     w%w%    h%h%   c%coltxt%  BackgroundTrans Center 0x200   ,%btname%
      else
	    {
        Gui,2:Add,Progress,        x%x%   y%y% w%w%  h%h%  Disabled Background%colbgr%       ;- TITLE Button-backgroundcolor
        Gui,2:Add,Text,            xp    yp     wp    hp   c%coltxt%  BackgroundTrans Center 0x200   ,%btname%
	    }
      stringsplit,z,column3,`|
    }
  else if (BTName !="" and column2 !="") 
    {
    ;---------------------------
    ;- after TITLE or SPACE > other buttons color background and text
    ;---
    Gui,2:font,s%z1%,%z2%
    if (pict="yes")        
	  {
	  Gui,2:add,picture ,            x%x%    y%y%     w%w%    h%h%   gStart1 v%btname%$%i%,%p2%                       ;- PICTURE ronded-corner behind TEXT /backgroundcolor Z3 has no effect
      Gui,2:Add,Text,                x%x%    y%y%     w%w%    h%h%   c%z4%  BackgroundTrans Center 0x200  ,%btname%   ; text bcc
	  }
    else
      {
	  ;Gui,2:add,picture ,            x%x%    y%y%     w%w%    h%h%   gStart1 v%btname%$%i%,%p2%                        ;- PICTURE ronded-corner behind TEXT /backgroundcolor Z3 has no effect
      ;Gui,2:Add,Text,                xp    yp     wp    hp   c%Z4%  BackgroundTrans Center 0x200  ,%btname%
      ;-
      Gui,2:Add,Progress,            x%x%   y%y% w%w%  h%h%  Disabled Background%Z3%
      Gui,2:Add,Text,                xp    yp     wp    hp   c%Z4%  BackgroundTrans Center 0x200 gStart1 v%btname%$%i% ,%btname%
	  }
    }
  y+=%v%
  Md:=mod(i,vert)
  if md=0
     x+=(wa*15)/xx,y:=(ha*1)/xx   ;- if modulo = 0 them move to new x (right)  y (top)
  }
;--- 2 Buttons if needed instead of ESC  or alt+ESC -------------------
x:=(wa*45)/xx,y:=(ha*81.8)/xx,w:=(wa*8)/xx,h:=(ha*2.4)/xx 
Gui,2:add,button,x%x% y%y% h%h% w%w% gMinimize,MINIMIZE
;-
x:=(wa*31.2)/xx,y:=(ha*77.7)/xx,w:=(wa*8)/xx,h:=(ha*3.1)/xx 
Gui,2:add,button,x%x% y%y% h%h% w%w% gClose,EXIT
;--------- GUISIZE -------------------------------------------------------
x:=(wa*20)/xx,y:=(ha*12)/xx,w:=(wa*67)/xx,h:=(ha*85)/xx   ;- GUI x y w h
Gui,2:Show, x%x% y%y% h%h% w%w%,%filename1%
OnMessage(0x201, "WM_LBUTTONDOWN") ;0x201 is the number for Windows Message WM_LBUTTONDOWN, which is the message Windows sends when the mouse clicks on our window.
Return
;-------------------------------------------------------------------------
CLOSE:
2Guiclose:
exitapp
;--------------
Minimize:
Gui,2:minimize
return
;-------------------------------------------------------------------------
!esc::exitapp                                                                       ;- EXIT
esc::Gui,2:minimize                                                                 ;- minimize this script with alt+ESC
;--------------- start --------------------------
start1:
gui,2:submit,nohide
r:= a_guicontrol          ;- vVar ( Buttonname )
a:=StrSplit(r,"$")
df:=a[2]
clm2:= m%df%,clm3:= n%df%,clm4:= o%df%
;msgbox, 262208, ,R=%r%`nCT=%ct%`nCTRL=%ctrl%`nURL1=%clm2%`nURL2=%clm3%`nURL3=%clm4%
;return
;----
try
 run,%clm2%
catch,err 
  { 
  gosub,checkerror
  return
  }
try
 run,%clm3%
catch,err
  { 
  gosub,checkerror
  return
  }
try
 run,%clm4%
catch,err 
  { 
  gosub,checkerror
  return
  }
;Gui,2:minimize
return
;-----------------
Checkerror:
    x1:="Message=" . err.Message
    x2:="Extra  =" . err.extra
    x3:="File   =" . err.file
    x4:="Line   =" . err.line
    x5:="What   =" . err.what
    msgbox, 262208,ERROR,Error=`n%x1%`n----------------------`n%x2%`n%x3%`n%x4%`n%x5%`n--------------------`n
return

WM_LBUTTONDOWN(wParam, lParam, msg, hwnd)
{
Gui, +LastFound
Checkhwnd := WinExist()
if hwnd = %Checkhwnd%
{
PostMessage, 0xA1, 2 ;-0xA1 is WM_NCLBUTTONDOWN, to make Windows think we clicked on the non-client area of the window (the border).
                     ;-The "2" tells windows we clicked on caption at the top of the window, as if to drag it.
}
}

;================================ END SCRIPT ================================
20221113150311_screenshot.png
20221113150311_screenshot.png (1.91 MiB) Viewed 1811 times

Re: LCARS Star Trek

Posted: 12 Nov 2022, 17:06
by jrachr
@garry. Tk's garry.Almost there. Just have to make transparent background and figure out how to make the buttons like attached html. And maybe a controllable background for the folder titles.IE toggle on /off if background doesn't work for titles or ability to comment out.

https://www.thelcars.com/buttons.php

Re: LCARS Star Trek

Posted: 13 Nov 2022, 04:24
by garry
I'm not good in this . Maybe someone can help ...