You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tdetoys/kweather
Michele Calgaro 7fc1f5e515
Replace TQ_*Focus* and TQ_Scale* defines
1 year ago
..
data Resolve ambiguous station names 4 years ago
graphics KWeather: use glob to find and install weather icons 3 years ago
AUTHORS Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago
CMakeL10n.txt kweather: Improve station list processing 4 years ago
CMakeLists.txt KWeather: Split Display module in two sumbodules 3 years ago
Makefile.am LIB_QT -> LIB_TQT conversion to align to updated admin module 6 years ago
README.txt kweather: Improve station list processing 4 years ago
appletconfig.ui KWeather: Split Display module in two sumbodules 3 years ago
configure.in.in Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago
dockwidget.cpp KWeather: improve icon loading and other fixes 1 year ago
dockwidget.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
genstations.pl kweather: Improve station list processing 4 years ago
hi16-app-kweather.png Fix invalid headers in PNG files and optimize for size 8 years ago
hi32-app-kweather.png Fix invalid headers in PNG files and optimize for size 8 years ago
hi48-app-kweather.png Fix invalid headers in PNG files and optimize for size 8 years ago
kcmweatherapplet.cpp KWeather: Split Display module in two sumbodules 3 years ago
kcmweatherapplet.desktop KWeather: Split Display module in two sumbodules 3 years ago
kcmweatherapplet.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
kcmweatherservice.cpp Code style improvements. 3 years ago
kcmweatherservice.desktop KWeather: Try another icon for Service settings 3 years ago
kcmweatherservice.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
kcmweatherstations.cpp KWeather: Split Display module in two sumbodules 3 years ago
kcmweatherstations.desktop KWeather: Split Display module in two sumbodules 3 years ago
kcmweatherstations.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
kweather.cpp KWeather: Place Service section before Stations 3 years ago
kweather.desktop Desktop file translations: 5 years ago
kweather.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
kweather.kdevprj Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago
kweatherreport.desktop Update XDG information in support of bug report 892. 13 years ago
kweatherservice.desktop Desktop file translations: 5 years ago
main.cpp Rename additional header files to avoid conflicts with KDE4 12 years ago
metar_parser.cpp KWeather: improve icon loading and other fixes 1 year ago
metar_parser.h KWeather: improve icon loading and other fixes 1 year ago
metar_parser_test.cpp Rename KLocale to enhance compatibility with KDE4 12 years ago
reportmain.cpp Rename additional header files to avoid conflicts with KDE4 12 years ago
reportview.cpp KWeather: improve icon loading and other fixes 1 year ago
reportview.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
serviceconfig.ui KWeather: Split Display module in two sumbodules 3 years ago
sidebarwidget.cpp Sidebar: enforce icon update after settings change 3 years ago
sidebarwidget.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
stationdatabase.cpp rename the following methods: 13 years ago
stationdatabase.h Rename additional header files to avoid conflicts with KDE4 12 years ago
stationdatabase_test.cpp Rename KDEHOME and KDEDIR 13 years ago
stationsconfig.ui KWeather: Split Display module in two sumbodules 3 years ago
stationsconfigwidget.cpp KWeather: improve icon loading and other fixes 1 year ago
stationsconfigwidget.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
sun.cpp rename the following methods: 13 years ago
sun.h Rename old tq methods that no longer need a unique name 13 years ago
sun_test.cpp Trinity Qt initial conversion 15 years ago
test.sh Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago
weatherIface.h Trinity Qt initial conversion 15 years ago
weather_icon.cpp KWeather: improve icon loading and other fixes 1 year ago
weather_icon.h KWeather: improve icon loading and other fixes 1 year ago
weather_stations.desktop.in Remove unwanted end spaces in kweather-stations.desktop. 3 years ago
weatherbar.cpp KWeather Sidebar: timer fixes 3 years ago
weatherbar.desktop KWeather Konqueror sidebar revival 3 years ago
weatherbar.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
weatherbar_add.desktop KWeather Konqueror sidebar revival 3 years ago
weatherbutton.cpp Replace TQ_*Focus* and TQ_Scale* defines 1 year ago
weatherbutton.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
weatherlib.cpp KWeather: improve icon loading and other fixes 1 year ago
weatherlib.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
weatherlog.sh Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago
weatherservice.cpp KWeather: improve icon loading and other fixes 1 year ago
weatherservice.h Replace Q_OBJECT with TQ_OBJECT 1 year ago
weathersig.sh Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. 15 years ago

README.txt

January 2021
====================
Stations are retrieved from https://tgftp.nws.noaa.gov/data/nsd_cccc.txt

wget -O data/nsd_cccc.txt https://tgftp.nws.noaa.gov/data/nsd_cccc.txt

dos2unix data/nsd_cccc.txt

data/station_names.txt is used to provide correct orthography of the area
where the station is located, which is used in the configuration dialog 
of kweather applet.

The format of station_names.txt is ICAO;status;region_state;name;INFO1;INFO2

If status is one of none|false|na|decomissioned the station is ignored.
INFO1 is what was previously the 5th position in weather_stations.desktop
makred with ------
INFO2 is what was previously the 6th position in weather_stations.desktop
makred with ---

The source nsd_cccc.txt has illed information and structure that needs to be
corrected in the files used in kweather. Some of the problems are:
1. decomissioned stations
2. names of station locations

The genstations.pl is based on following idea

Based on the input nsd_cccc.txt and the station_names.txt file we can 
generate stations.dat like following:

  for each station in nsd_cccc.txt do
	check if station ID matches one in station_names.txt
	if it matches then
    	use the name of the station
    else
    	use the name from nsd_cccc.txt
    write entry/line in stations.dat
    
Based on stations.dat and weather_stations.desktop.in we can generate 
weather_stations.desktop.
weather_stations.desktop will be updated with the names from stations.dat 
and the additional information will be preserved like following.
  for each station in stations.dat 
	for each region from weather_stations.desktop.in 
		if state is provided in stations.dat
			use the state to build a key with region and state
		else
			for each state in the states of the region
				use the state to build a key
				if section for this key exists
				    and
					if name of the section matches
						stop processing
						proper section was found
						we add the station here
                        write entry for the station 

There are few problems with this approach and the ill provided nsd_cccc.txt data

1. States are missing and thus correlation between station and state can not be done
2. When State is missing, based on the country/state name some entries are ambig
	Example Georgia and US state of Georgia

Country list seemed to be used for the country names and as convention here
wget ftp://ftp.ncdc.noaa.gov/pub/data/noaa/country-list.txt but the FIPS notation was 
dropped in 2008 as a standard, however continiues to be used.

    "The Census Bureau decided that, based on decades of using the terminology FIPS to
    describe its codes, it would continue to use the FIPS name for its updated codes, 
    where FIPS now stood for FIP "Series", since there no longer existed an official 
    FIP "Standard". [https://en.wikipedia.org/wiki/FIPS_county_code]

A mapping to ISO 3166 ALPHA-2 https://laendercode.net/en/2-letter-list.html
seems more appropriate.

TODO: check the country code mapping in weather_stations.desktop.in